[ntpwg] Comments on NTP draft -06
David L. Mills
mills at udel.edu
Thu Jun 28 20:39:00 UTC 2007
Warner,
There have been some recent changes, but your description is
substantially correct. See the leap second section in the ntp-dev
documentation for the ntpd program.
Specifically, the current code can use the lNIST eapseconds file even
without the crypto code. The NIST leapseconds file is refreshed about
once every six months, even if nothing has changed. If the file is
present and a leap has been announced at a specific NTP second in
future, the daemon computes the number of seconds remaining until the
leap. If the number of seconds is less than a month, the system leap
bits are set. If leass than a day, the kernel is armed for the leap.
If kernel code is not available or disabled, the leap is implemented as
an ugly step. If the Unix system clock code is as recommended in the
nanokernel distribution, the kernel clock will appear to be set
backward, but stand still or slowly advance during the leap second.
If the leapseonds table is not present and a plurality of server leap
bits are set, the number of NTP seconds until the end of the month is
computed from calendar calculations and it operates as above.
A small number of issues remain, such as what to do about expired
leapsecond files, what to do if the leapsecond information is downloaded
from a crypto server, etc. The paint ain't quite dry yet.
Dave
M. Warner Losh wrote:
> In message: <20070628161216.GA16642 at ucolick.org>
> Steve Allen <sla at ucolick.org> writes:
> : On Thu 2007-06-28T10:11:49 -0400, Danny Mayer hath writ:
> : > > LI Leap Indicator (leap): 2-bit integer warning of an impending leap
> : > > second to be inserted or deleted in the last minute of the current
> : > > month with values defined in Figure 10.
> : > >
> : > > +-------+-------------------------------------------------+
> : > > | Value | Meaning |
> : > > +-------+-------------------------------------------------+
> : > > | 0 | no warning |
> : > > | 1 | last minute of the day has 61 seconds |
> : > > | 2 | last minute of the day has 59 seconds |
> : > > SB> surely last minute of the last day of the month has X seconds?
> : >
> : > Not exactly. It's actually the last day of a specific quarter though I
> : > don't think it's ever happened yet on any day but the last day of
> the year.
>
> "Day" is right here, at least from historical ntp implementation point
> of view. These implementations turn on the 'today is leap second day'
> in the kernel, which implements its local policy for doing that when
> they see these bits set.
>
> : No, not the quarter. The text is right to use "month". ITU-R TF.460
> : allows for a leap second on the last day of *any* month. That's
> : another point in favor of including a reference to the official
> : document.
>
> Current ntp implementations limit this to the quarterly, and filters
> them when it isn't leap day.
>
> : Perhaps the original point was that when the LI is 0 then the last
> : minute of the month should default to 60 seconds?
>
> I think that's good, or a separate value to distinguish
>
> Warner
> _______________________________________________
> ntpwg mailing list
> ntpwg at support.ntp.org
> https://support.ntp.org/mailman/listinfo/ntpwg
More information about the ntpwg
mailing list