[ntp:hackers] Simulate leap second
juergen perlinger
juergen.perlinger at t-online.de
Sat Dec 28 11:34:35 UTC 2013
On 12/27/2013 09:52 PM, Hal Murray wrote:
> catherinewilliams888 at gmail.com said:
>> I want to simulate leap second case. I have one linux server as NTP server.
>> How can I make the server get leap second indicate?
> I'm not sure what you want to do.
>
> There is a leap-file option to the config stuff. You can get the current
> file from the web and edit it. (There may be a checksum in there so it might
> be more complicated than a simple edit.) That will make a leap second on
> that system at the end of the day you pick. Is that what you want to do?
>
> It will also tell other ntp clients that a leap-second is pending. I think
> current ntpd needs a majority of servers to set the leap-second. I think
> older versions only needed one server.
>
>
The good news is that NTPD does not validate the check sum of the leap
seconds file, so simply using the editor is definitely an option. You
have to make sure that the leap second time stamp is really the
beginning of a month, or it will be rejected.
But indeed the majority of other servers for a daemon instance must
indicate a scheduled leap second transition for the daemon to accept it.
This is not true for reference clocks -- if ANY of them indicates a leap
second, the daemon will take this as a fact. But only if it's the
beginning of a month after the expiration of an existing table file, if
there is one.
Given all the constraints that were created to avoid stray leap second
transitions, you will likely have to tweak the system time to somewhat
before a transition and refrain from synchronisation with everything
that would put the system time back to the tracks. Whether you could do
all you want with a single isolated system running as an orphaned node
or with a time island of several nodes is something I cannot discern
without a more detailed description of the objective.
Cheers,
Pearly
More information about the hackers
mailing list