[ntp:questions] Failed to test leapsecond's handling

David Lord snews at lordynet.org
Thu Mar 8 13:32:44 UTC 2012


Marco Marongiu wrote:
> Hi all
> 
> I finally arranged a box to test how the leap second is managed, but not
> sure I got it right, as basically nothing seems to be happening. Can you
> help me to understand what I am doing wrong?
> 
> Configuration and test files are included at the end of this message.
> 
> I installed a Dell Optiplex 745 with Debian Squeeze, updated with the
> latest security patches.
> 
> I then tried to set up things as planned, also following Martin Burnicki
> suggestions (see his message to this list at http://tinyurl.com/75dtnhk).
> 
> After some fruitless attempts to set up the node in orphan mode, I
> decided to sync it with its own local clock.
> 
> I succeed arming a leap second with the combination: move clock to June
> 30th + sync to local clock + use leap seconds file. Watching the output
> of "ntpq -c pe -c rv", I correctly see the leap_add_sec and the
> leap_armed bits set before the leap second happens, and leap_none and
> leap_event set afterwards.
> 
> But when I graph the time log (see the log target in the makefile), I
> don't see the leap second kicking in. Based on Mills' "The NTP Timescale
> and Leap Seconds"[1], when the leap second kicks in, I'd expect two
> consecutive date command to _appear_ happen at different offset than in
> normal conditions. Unfortunately, that didn't happen, and if I draw a
> line of the accumulated offsets between consecutive runs of the command,
> the line is almost perfectly straight.
> 
> What am I doing wrong?
> 

........

> 
> ---8<--- ntp.conf.local ---8<------8<------8<------8<------8<------8<---
> driftfile /var/lib/ntp/ntp.drift
> 
> statistics loopstats peerstats clockstats
> filegen loopstats file loopstats type day enable
> filegen peerstats file peerstats type day enable
> filegen clockstats file clockstats type day enable
> 
> server 127.127.1.0
> fudge 127.127.1.0 stratum 10
> 
> leapfile "/etc/leap-seconds"
> 
> restrict -4 default kod notrap nomodify nopeer noquery
> restrict -6 default kod notrap nomodify nopeer noquery
> 
> restrict 127.0.0.1
> restrict ::1
> ---8<------8<------8<------8<------8<------8<------8<------8<------8<---
> 
> An excerpt of the time log for 23:59:59.00 - 00:00:01.00 can be found at
> http://pastebin.com/GjgiFZ68


I'm just guessing :-)

I thought that you needed a real refclock but it's
possible 127.127.1.0 is ok. The other criteria is that
stratum should be 1.

Try with fudge 127.127.1.0 stratum 1


David



More information about the questions mailing list