Hello

On 28.03.2012 22:09, AlbyVA wrote:
  O yes... Daddy likes. :)

[godzilla] ./test-time
16:08:18.987,
16:08:19.991,
16:08:20.996,
16:08:22.001,
16:08:23.007,
^C

As you can see in your own output, you still have the problem, that depending on the run time of the processes in the loop, you may miss a second. This could also be the leap second. :)

Do something like this, which has been mention already here from Daniel Norton (on one line, the relevant part is doing the loop 240 times and only half a second sleep):

for i in `seq 0 240` ; do ntptime | awk '/time d3/ {print $3" "$4" "$5" "$6" "$7}' | sed 's/,$//' ; sleep 0.5 ; done

This will give you the following output:
Wed, Mar 28 2012 23:50:44.355
Wed, Mar 28 2012 23:50:44.865
Wed, Mar 28 2012 23:50:45.380
Wed, Mar 28 2012 23:50:45.894
Wed, Mar 28 2012 23:50:46.415
Wed, Mar 28 2012 23:50:46.925
Wed, Mar 28 2012 23:50:47.453
Wed, Mar 28 2012 23:50:47.980
Wed, Mar 28 2012 23:50:48.503
Wed, Mar 28 2012 23:50:49.027
Wed, Mar 28 2012 23:50:49.548
Wed, Mar 28 2012 23:50:50.064
Wed, Mar 28 2012 23:50:50.597
^C

Most seconds will be displayed twice, but at least you won't miss any single one at all.


bye
Fabian
_______________________________________________
pool mailing list
[email protected]
http://lists.ntp.org/listinfo/pool

Reply via email to