[ntp:questions] Re: ntpd -x

David L. Mills mills at udel.edu
Thu Jan 26 18:30:14 UTC 2006


Joel,

The only thing the -x option does is change the step threshold to 600 s, 
or ten minutes. I find it mighty curious that you would consider a large 
discrepancy like that within acceptable bounds for a any consistent 
distributed data system, but that's not my call.

If you really do insist on disabling all steps, put a "tinker step 0" 
and "tinker panic 0" in the configuration file. Be advised, should the 
correction be many hours or days, the time to amortize the correction 
will be months or years. Also, be sure to disable the kernel discipline 
if available. In some systems like Solaris which have broken the 
original Unix adjtime() model, a large correction becomes unstable and 
results in wild swings that can take many hours or days to damp out.

Note that the tinkers disable all steps for any reason, including a step 
at startup. If you need that, you will need another program or to start 
ntpd in ntpdate mode before launching the daemon.

Dave

Joel Shellman wrote:

> Looking at:
> 
> http://www.eecis.udel.edu/~mills/ntp/html/ntpd.html
> 
> It says:
> 
> "As the result of this behavior, once the clock has
> been set, it very rarely strays more than 128 ms, even
> under extreme cases of network path congestion and
> jitter. Sometimes, in particular when ntpd is first
> started, the error might exceed 128 ms. This may on
> occasion cause the clock to be set backwards if the
> local clock time is more than 128 s in the future
> relative to the server. In some applications, this
> behavior may be unacceptable. If the -x option is
> included on the command line, the clock will never be
> stepped and only slew corrections will be used."
> 
> But then at the bottom, in the discussion of command
> line args, it says:
> 
> "-x
>     Normally, the time is slewed if the offset is less
> than the step threshold, which is 128 ms by default,
> and stepped if above the threshold. This option sets
> the threshold to 600 s, which is well within the
> accuracy window to set the clock manually. Note: Since
> the slew rate of typical Unix kernels is limited to
> 0.5 ms/s, each second of adjustment requires an
> amortization interval of 2000 s. Thus, an adjustment
> as much as 600 s will take almost 14 days to complete.
> This option can be used with the -g and -q options.
> See the tinker command for other options. Note: The
> kernel time discipline is disabled with this option."
> 
> This seems to imply that if the offset is greater than
> 600s a step would occur. Is this correct? I understand
> that a difference of 1000s would result in ntpd
> exiting anyway, but in that space between 600-1000s, a
> step could occur even with -x specified? I'm asking
> because it's a requirement that we never have the time
> stepped (especially not backwards) except at startup.
> I know we can run -q -g at startup, but I want to
> ensure that it is not possible to step the clock after
> startup. I would rather have ntpd exit.
> 
> Thank you,
> 
> -joel
> 
> __________________________________________________
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam protection around 
> http://mail.yahoo.com 
> _______________________________________________
> questions mailing list
> questions at lists.ntp.isc.org
> https://lists.ntp.isc.org/mailman/listinfo/questions
> 




More information about the questions mailing list