Search Results

Search found 347 results on 14 pages for 'timestamps'.

Page 1/14 | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Correlating /var/log/* timestamps

    - by intuited
    /var/log/messages, /var/log/syslog, and some other log files use a timestamp which contains an absolute time, like Jan 13 14:13:10. /var/log/Xorg.0.log and /var/log/dmesg, as well as the output of $ dmesg, use a format that looks like [50595.991610] malkovich: malkovich malkovich malkovich malkovich I'm guessing/gathering that the numbers represent seconds and microseconds since startup. However, my attempt to correlate these two sets of timestamps (using the output from uptime) gave a discrepancy of about 5000 seconds. This is roughly the amount of time my computer was suspended for. Is there a convenient way to map the numeric timestamps used by dmesg and Xorg into absolute timestamps?

    Read the article

  • unix timestamps and php

    - by sea_1987
    I have a list of unix timestamps in a database, and I wanting to select the ones that are from today. i.e If today is Tueday, I want to get all the timestamps that were made today? Is it possible? Is there such a things as strtotime("Today")? Any help would be great

    Read the article

  • Grouping timestamps by interval between timestamps, then calculating from group MySQL

    - by Emile
    To put this question into context, I'm trying to calculate "time in app" based on an event log. Assume the following table: user_id event_time 2 2012-05-09 07:03:38 3 2012-05-09 07:03:42 4 2012-05-09 07:03:43 2 2012-05-09 07:03:44 2 2012-05-09 07:03:45 4 2012-05-09 07:03:52 2 2012-05-09 07:06:30 I'd like to get the difference between the highest and lowest event_time from a set of timestamps that are within 2 minutes of eachother (and grouped by user). If a timestamp is outside of a 2 minute interval from the set, it should be considered a part of another set. Desired output: user_id seconds_interval 2 7 (because 07:03:45 - 07:03:38 is 7 seconds) 3 0 (because 07:03:42) 4 9 (because 07:03:52 - 2012-05-09 07:03:43) 2 0 (because 07:06:30 is outside 2 min interval of 1st user_id=2 set) This is what I've tried, although I can't group on seconds_interval (even if I could, I'm not sure this is the right direction): SELECT (max(tr.event_time)-min(tr.event_time)) as seconds_interval FROM some_table tr INNER JOIN TrackingRaw tr2 ON (tr.event_time BETWEEN tr2.event_time - INTERVAL 2 MINUTE AND tr2.event_time + INTERVAL 2 MINUTE) GROUP BY seconds_interval

    Read the article

  • Subversion to TFS 2010 RTM migration with timestamps

    - by ooOOoo
    Question is simple, if one needs to migrate subversion repository to TFS 2010 RTM what is the best tool to use. I have found http://www.timelymigration.com/ and looks good but after contacting them I found out that during the migration timestamps on the changesets are lost. All timestamps are set to date of migration and real timestamps are stored in the comment of the changeset. How to migrate from SVN to TFS 2010 RTM and keep the timestamps ??

    Read the article

  • List full timestamps of files in a tarball

    - by Mechanical snail
    I have a large tar archive and want to see the exact (nanosecond) timestamps that are stored for each file in the archive. In case it's relevant, the tarball is in POSIX-2001 format (tar --format=posix). tar --list --verbose displays the timestamps rounded off to the minute. For comparison, ls --full-time does what I want, but I'd rather not have to extract everything first because it's huge. For my purposes, command-line and GUI tools are both fine.

    Read the article

  • Setting creation or change timestamps

    - by Thanatos
    Using utimes, futimes, futimens, etc., it is possible to set the access and modification timestamps on a file. Is there a function to set change timestamps? (I understand the cyclic nature of wanting to change the change timestamp, but think archiving software - it would be nice to restore a file exactly as it was.) Are there any functions at all for creation timestamps? (I realize that ext2 does not support this, but I was wondering if Linux did, for those filesystems that do support it.) If it's not possible, what is the reasoning behind it not being so?

    Read the article

  • git rebase without changing commit timestamps

    - by Olivier
    Would it make sense to perform git rebase while preserving the commit timestamps? I believe a consequence would be that the new branch will not necessarily have commit dates chronologically. Is that theoretically possible at all? (e.g. using plumbing commands; just curious here) If it is theoretically possible, then is it possible in practice with rebase, not to change the timestamps? For example, assume I have the following tree: master <jun 2010> | : : : oldbranch <feb 1984> : / oldcommit <jan 1984> Now, if I rebase oldbranch on master, the date of the commit changes from feb 1984 to jun 2010. Is it possible to change that behaviour so that the commit timestamp is not changed? In the end I would thus obtain: oldbranch <feb 1984> / master <jun 2010> | : Would that make sense at all? Is it even allowed in git to have a history where an old commit has a more recent commit as a parent? Edit A crucial question of Von C helped me understand what is going on: when your rebase, the committer's timestamp changes, but not the author's timestamp, which suddenly all makes sense. So my question was actually not precise enough. The answer is that rebase actually doesn't change the author's timestamps (you don't need to do anything for that), which suits me perfectly.

    Read the article

  • Preserving timestamps on Clojure .clj files when building shaded jar via Maven Shade Plugin

    - by Dereference
    When using the maven-shade-plugin to package our jar artifact that contained a few Clojure libs and some Java. We were using AOT compilation for our Clojure code. When we loaded the jar, it was having very slow load times. AOT compilation is supposed to help this quite a bit, but that wasn't what we were seeing. We noticed in java jar -verbose output that there was a lot of JVM__DEFINE_CLASS calls happening when Clojure classes were being loaded. This didn't make sense, since more of our Clojure code was AOT compiled to .class files. Turns out the maven-shade-plugin creates all new files, with new timestamps in the final artifact Clojure uses the timestamp information on a .clj file vs. a .class file, to determine if the file needs to be recompiled. The maven-shade-plugin was causing the .clj file and it's associated .class file to have the same timestamp, so Clojure always chose to dynamically recompile the source. The only workaround that we have been able to figure out, at this point, is to write a script that would re-open the shaded jar and bump the .clj file timestamps back to some time in the past, so that they wouldn't be equal to the timestamps of their associated .class files. Does anyone know of a better approach?

    Read the article

  • Determining difference in timestamps for two values in the same MySQL table

    - by JayRizzo03
    I am relatively new to programming in PHP, so I apologize if this is a rather simple question. I have a MySQL database table called MachineReports that contains the following values: ReportNum(primary key, auto increment), MachineID and Timestamp Here is some example data: |ReportNum | MachineID | Timestamp | |1 | AD3203 | 2012-11-18 06:32:28| |2 | AD3203 | 2012-11-19 04:00:15| |3 | BC4300 | 2012-11-19 04:00:15| What I am attempting to do is find the difference in timestamps in seconds for each machine ID by iterating over each row set. I am getting stuck on the best way to do this, however. Here is the code I've written so far: <?php include '../dbconnect/dbconnect.php'; $machineID=[]; //Get a list of all MachineIDs in the database foreach($dbh->query('SELECT DISTINCT(MachineID) FROM MachineReports') as $row) { array_push($machineID, $row[0]); } for($i=0;$i<count($machineID);$i++){ foreach($dbh->query("SELECT MachineID FROM MachineReports WHERE MachineID='$machineID[$i]' ORDER BY MachineID") as $row) { //code to associate each machineID with two time stamps goes here } } ? This code just lists out the contents of the table row by row. My ultimate goal is to find the difference in timestamps for a certain MachineID. One of the things I've considered is using a multidimensional array in php - using the $machineID as the key and then storing the timestamp inside the array the key points to. However, I'm uncertain how to do that since my query parses row by row. I have quite a few questions. 1) Is this the most efficient way to be doing this? I suspect my database table design may not be the best. 2)What would be the best way to determine the difference in timestamps for a certain machineID? Even just a pointer to a topic that would prompt me to think about this in a different way would be helpful - I'm not afraid to do research. Thanks!

    Read the article

  • How do I change folder timestamps recursively?

    - by MonkeyWrench32
    I was wondering if anyone knows how to change the timestamps of folders recursively based on the latest timestamp found of the files in that folder. So for example: jon@UbuntuPanther:/media/media/MP3s/Foo Fighters/(1997-05-20) The Colour and The Shape$ ls -alF total 55220 drwxr-xr-x 2 jon jon 4096 2010-08-30 12:34 ./ drwxr-xr-x 11 jon jon 4096 2010-08-30 12:34 ../ -rw-r--r-- 1 jon jon 1694044 2010-04-18 00:51 Foo Fighters - Doll.mp3 -rw-r--r-- 1 jon jon 3151170 2010-04-18 00:51 Foo Fighters - Enough Space.mp3 -rw-r--r-- 1 jon jon 5004289 2010-04-18 00:52 Foo Fighters - Everlong.mp3 -rw-r--r-- 1 jon jon 5803125 2010-04-18 00:51 Foo Fighters - February Stars.mp3 -rw-r--r-- 1 jon jon 4994903 2010-04-18 00:51 Foo Fighters - Hey, Johnny Park!.mp3 -rw-r--r-- 1 jon jon 4649556 2010-04-18 00:52 Foo Fighters - Monkey Wrench.mp3 -rw-r--r-- 1 jon jon 5216923 2010-04-18 00:51 Foo Fighters - My Hero.mp3 -rw-r--r-- 1 jon jon 4294291 2010-04-18 00:52 Foo Fighters - My Poor Brain.mp3 -rw-r--r-- 1 jon jon 6778011 2010-04-18 00:52 Foo Fighters - New Way Home.mp3 -rw-r--r-- 1 jon jon 2956287 2010-04-18 00:51 Foo Fighters - See You.mp3 -rw-r--r-- 1 jon jon 2730072 2010-04-18 00:51 Foo Fighters - Up in Arms.mp3 -rw-r--r-- 1 jon jon 6086821 2010-04-18 00:51 Foo Fighters - Walking After You.mp3 -rw-r--r-- 1 jon jon 3033660 2010-04-18 00:52 Foo Fighters - Wind Up.mp3 The folder "(1997-05-20) The Colour and The Shape" would have its timestamp set to 2010-04-18 00:52. Thanks in advance!

    Read the article

  • How can I copy files with timestamps between 2 times and preserve the directory structure

    - by brushwood
    I want to copy files that have timestamps from the time the script begins to run and a hour previous. So I am basically trying to emulate robocopy but with minage and maxage going down to the exact time rather than days. So far I have this in powershell: $now = Get-Date $previousHour = $now.AddHours(-1) "Copying files from $previousHour to $now" function DoCopy ($source, $destination) { $fileList = gci $source -Recurse foreach ($file in $fileList) { if($file.LastWriteTime -lt $now -and $file.LastWriteTime -gt $previousHour) { #Do the copy } } } DoCopy "C:\test" "C:\test2" but if I try to do the copy like that, it copies all the files directly into the destination folder rather than the subfolders.enter code here

    Read the article

  • Micro Second resolution timestamps on windows.

    - by Nikhil
    How to get micro second resolution timestamps on windows? I am loking for something better than QueryPerformanceCounter, QueryPerformanceFrequency (these can only give you an elapsed time since boot, and are not necessarily accurate if they are called on different threads - ie QueryPerformanceCounter may return different results on different CPUs. There are also some processors that adjust their frequency for power saving, which apparently isn't always reflected in their QueryPerformanceFrequency result.) There is this, http://msdn.microsoft.com/en-us/magazine/cc163996.aspx but it does not seem to be solid. This looks great but its not available for download any more. http://www.ibm.com/developerworks/library/i-seconds/ This is another resource. http://www.lochan.org/2005/keith-cl/useful/win32time.html But requires a number of steps, running a helper program plus some init stuff also, I am not sure if it works on multiple CPUs Also looked at the Wikipedia link on the subject which is interesting but not that useful. http://en.wikipedia.org/wiki/Time_Stamp_Counter If the answer is just do this with BSD or Linux, its a lot easier thats fine, but I would like to confirm this and get some explanation as to why this is so hard in windows and so easy in linux and bsd. Its the same damm hardware...

    Read the article

  • Javascript timezone solution needed(taking into account the actual difference in UTC timestamps)

    - by user198729
    I have unix timestamps from time zone X which is not known, the current timestamp(now()) in TZ X is known 1275143019, how to approach a javascript function so that it can generate the datetime in the users current TZ in the format 2010-05-29 15:32:35 ? UPDATE I'm not a unix timestamp expert,if unix timestamp is always the same in different TZ, then I have to change the question a little,so that the current datetime in TZ X is known(like 2010-05-29 22:32:28),and the other datetime is also in this format,how to convert them to the user's TZ based on the difference between now() ? UPDATE Something strange from MySQL: On server: mysql> select now(); +---------------------+ | now() | +---------------------+ | 2010-05-29 18:34:30 | +---------------------+ 1 row in set (0.00 sec) mysql> select UNIX_TIMESTAMP(); +------------------+ | UNIX_TIMESTAMP() | +------------------+ | 1275143674 | +------------------+ 1 row in set (0.00 sec) On local: mysql> select now(); +---------------------+ | now() | +---------------------+ | 2010-05-29 22:41:30 | +---------------------+ 1 row in set (0.00 sec) mysql> select UNIX_TIMESTAMP(); +------------------+ | UNIX_TIMESTAMP() | +------------------+ | 1275144091 | +------------------+ 1 row in set (0.00 sec) Why the difference between now() (2010-05-29 22:41:30-2010-05-29 18:34:30=6hours) and UNIX_TIMESTAMP() (1275144091 - 1275143674 = 417seconds) is not the same ?

    Read the article

  • Resolving SNAPSHOT dependencies with timestamps from Ivy

    - by bradhouse
    I am attempting to resolve timestamped SNAPSHOT dependencies with Ivy. The environment is Ant + Ivy 1.2.0 + Archiva. Archiva itself is populated from Maven2 builds. Ivy is only used to resolve dependencies (from a single, non Maven2 project). How can Ivy be configured to correctly resolve timestamped artifacts from an Archiva or m2 repository? For reference my current configuration is: ivysettings.xml looks similar to: <ivysettings> <settings defaultResolver="archiva-chain"/> <resolvers> <chain name="archiva-chain" changingPattern=".*SNAPSHOT" checkmodified="true"> <ibiblio name="archiva-internal" m2compatible="true" usepoms="true" pattern="[organization]/[module]/[revision]/[artifact]-[revision].[ext]" root="http://host:port/archiva/repository/internal"/> <ibiblio name="archiva-deploy" m2compatible="true" usepoms="true" pattern="[organization]/[module]/[revision]/[artifact]-[revision].[ext]" root="http://host:port/archiva/repository/deploy"/> <ibiblio name="archiva-snapshots" m2compatible="true" usepoms="true" pattern="[organization]/[module]/[revision]/[artifact]-[revision].[ext]" root="http://host:port/archiva/repository/snapshots"/> </chain> </resolvers> </ivysettings> The ivy.xml dependencies are simple: <ivy-module version="2.0"> <info organisation="com.myorg" module="myapp"/> <dependencies> <dependency org="com.myorg" name="myartifact" rev="1.8.0-SNAPSHOT" changing="true"/> </dependencies> </ivy-module> Ivy does not attempt to resolve a timestamped artifact. E.g. [ivy:retrieve] :: problems summary :: [ivy:retrieve] :::: WARNINGS [ivy:retrieve] module not found: com.myorg#myartifact;1.8.0-SNAPSHOT [ivy:retrieve] ==== archiva-internal: tried [ivy:retrieve] -- artifact com.myorg#myartifact;1.8.0-SNAPSHOT!myartifact.jar: [ivy:retrieve] http://host:port/archiva/repository/internal/com.myorg/myartifact/1.8.0-SNAPSHOT/myartifact-1.8.0-SNAPSHOT.jar [ivy:retrieve] ==== archiva-deploy: tried [ivy:retrieve] -- artifact com.myorg#myartifact;1.8.0-SNAPSHOT!myartifact.jar: [ivy:retrieve] http://host:port/archiva/repository/deploy/com.myorg/myartifact/1.8.0-SNAPSHOT/myartifact-1.8.0-SNAPSHOT.jar [ivy:retrieve] ==== archiva-snapshots: tried [ivy:retrieve] -- artifact com.myorg#myartifact;1.8.0-SNAPSHOT!myartifact.jar: [ivy:retrieve] http://host:port/archiva/repository/snapshots/com.myorg/myartifact/1.8.0-SNAPSHOT/myartifact-1.8.0-SNAPSHOT.jar [ivy:retrieve] :::::::::::::::::::::::::::::::::::::::::::::: [ivy:retrieve] :: UNRESOLVED DEPENDENCIES :: [ivy:retrieve] :::::::::::::::::::::::::::::::::::::::::::::: [ivy:retrieve] :: com.myorg#myartifact;1.8.0-SNAPSHOT: not found [ivy:retrieve] :::::::::::::::::::::::::::::::::::::::::::::: [ivy:retrieve] [ivy:retrieve] [ivy:retrieve] :: USE VERBOSE OR DEBUG MESSAGE LEVEL FOR MORE DETAILS There is a maven-metadata.xml in snapshots/com/myorg/myartifact: <?xml version="1.0" encoding="UTF-8"?> <metadata> <groupId>com.myorg</groupId> <artifactId>myartifact</artifactId> <versioning> <latest>1.8.0-SNAPSHOT</latest> <versions> <version>1.3.0-SNAPSHOT</version> <version>1.4.2-SNAPSHOT</version> <version>1.6.1-SNAPSHOT</version> <version>1.8.0-SNAPSHOT</version> </versions> <lastUpdated>20100303003206</lastUpdated> </versioning> </metadata> The maven-metadata.xml in snapshots/com/myorg/myartifact/1.8.0-SNAPSHOT: <?xml version="1.0" encoding="UTF-8"?> <metadata> <groupId>com.myorg</groupId> <artifactId>myartifact</artifactId> <version>1.8.0-SNAPSHOT</version> <versioning> <snapshot> <buildNumber>7</buildNumber> <timestamp>20100303.003206</timestamp> </snapshot> <lastUpdated>20100303003206</lastUpdated> </versioning> </metadata> Not all that useful, but for completeness, the files in the directory snapshots/com/myorg/myartifact/1.8.0-SNAPSHOT for the referenced snapshot: -rw-r--r-- 1 archiva archiva 240670 Mar 3 10:32 myartifact-1.8.0-20100303.003206-7.jar -rw-r--r-- 1 archiva archiva 32 Mar 3 10:32 myartifact-1.8.0-20100303.003206-7.jar.md5 -rw-r--r-- 1 archiva archiva 40 Mar 3 10:32 myartifact-1.8.0-20100303.003206-7.jar.sha1 -rw-r--r-- 1 archiva archiva 4068 Mar 3 10:32 myartifact-1.8.0-20100303.003206-7.pom -rw-r--r-- 1 archiva archiva 32 Mar 3 10:32 myartifact-1.8.0-20100303.003206-7.pom.md5 -rw-r--r-- 1 archiva archiva 40 Mar 3 10:32 myartifact-1.8.0-20100303.003206-7.pom.sha1 -rw-r--r-- 1 archiva archiva 180821 Mar 3 10:32 myartifact-1.8.0-20100303.003206-7-sources.jar -rw-r--r-- 1 archiva archiva 32 Mar 3 10:32 myartifact-1.8.0-20100303.003206-7-sources.jar.md5 -rw-r--r-- 1 archiva archiva 40 Mar 3 10:32 myartifact-1.8.0-20100303.003206-7-sources.jar.sha1

    Read the article

  • How can I sort timestamps in perl ?

    - by ablimit
    I have several thousand objects with string property in the format of "yyyy-MM-ddTHH:mm:ssZ". I want to sort these objects ordered by time. Is there any useful packages or scripts for this ? (currently I'm just comparing individual numeric values and it seems it's not very efficient and neat)

    Read the article

  • Formatting Timestamps in Java

    - by Craig H
    Is there a way to format a UTC time into any arbitrary string format I want in java? Basically I was thinking of having some class take the timestamp and I pass it is string telling it how I want it formated, and it returns the formatted string for me. Is there a way to do this?

    Read the article

  • Log with timestamps that have millisecond accuracy & resolution in Windows C++

    - by Psychic
    I'm aware that for timing accuracy, functions like timeGetTime, timeBeginPeriod, QueryPerformanceCounter etc are great, giving both good resolution & accuracy, but only based on time-since-boot, with no direct link to clock time. However, I don't want to time events as such. I want to be able to produce an exact timestamp (local time) so that I can display it in a log file, eg 31-12-2010 12:38:35.345, for each entry made. (I need the millisecond accuracy) The standard Windows time functions, like GetLocalTime, whilst they give millisecond values, don't have millisecond resolution, depending on the OS running. I'm using XP, so I can't expect much better than about a 15ms resolution. What I need is a way to get the best of both worlds, without creating a large overhead to get the required output. Overly large methods/calculations would mean that the logger would start to eat up too much time during its operation. What would be the best/simplest way to do this?

    Read the article

  • Error in merging two sequences of timestamps to yield strings

    - by AruniRC
    The code sorts two input sequences - seq01 and seq02 - on the basis of their timestamp values and returns a sequence that denotes which sequence is to be read for the values to be in order. For cases where seq02's timestamp value is lesser than seq01's timestamp value we yield a "2" to the sequence being returned, else a "1". These denote whether at that point seq01 is to be taken or seq02 is to be taken for the data to be in order (by timestamp value). let mergeSeq (seq01:seq<_>) (seq02:seq<_>) = seq { use iter01 = seq01.GetEnumerator() use iter02 = seq02.GetEnumerator() while iter01.MoveNext() do let _,_,time01 = iter01.Current let _,_,time02 = iter02.Current while time02 < time01 && iter02.MoveNext() do yield "2" yield "1" } To test it in the FSI created two sequences a and b, a={1;3;5;...} and b={0;2;4;...}. So the expected values for let c = mergeSeq a b would have been {"2","1","2","1"...}. However I am getting this error: error FS0001: The type ''a * 'b * 'c' does not match the type 'int' EDIT After correcting: let mergeSeq (seq01:seq<_>) (seq02:seq<_>) = seq { use iter01 = seq01.GetEnumerator() use iter02 = seq02.GetEnumerator() while iter01.MoveNext() do let time01 = iter01.Current let time02 = iter02.Current while time02 < time01 && iter02.MoveNext() do yield "2" yield "1" } After running this, there's another error: call MoveNext. Somehow the iteration is not being performed.

    Read the article

1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >