[ntp:questions] Allan deviation survey
David L. Mills
mills at udel.edu
Wed Sep 15 01:34:04 UTC 2010
A feedback loop that minimizes time and frequency errors is a type-2
loop whether linear or not. NTP as specified and implanted is not
linear either, since it can use old samples in the clock filter
algorithmic, turns into a FLL at larger poll interval,. and has an
automatic poll-adjust mechanism. For the purposes here, only the clock
filter is significant.
I suspect you use the precision time support in the kernel and the
ntp_adjtime() syscall or their equivalents in Linux. This code, which is
a descendent of code I wrote for the Alpha, implements a linear, type-2
loop with the same impulse response and time constant as the daemon loop
used when the precision time support is not available. Both the daemon
and kernel loops and yours as well are, crudely put, lowpass filters.
What I suspect you did was control the frequency directly and move the
corner frequency of the PLL to up out of the way values by decreasing
the time constant exponent (shift), then doing the lowpass function
yourself. That might even give better results than the PLL alone.
However, the ntpd measurements are after the clock filter and before the
kernel call, while I suspect yours are after the discipline and before
the kernel call. The two measurements are not comparable. Look at it
this way. At a poll interval of 16 s, the PLL reduces a given time
offset by a factor of 256, so in fact a 1-ms offset actually causes a
4-microsecond change in the clock phase. If that were the criteria to
judge performance, ntpdt would look 256 times better than advertised. I
am not here judging whether chrony is better than ntpd or not, just that
the performance measurements be comparable and honest.
>On 2010-09-14, David L. Mills <mills at udel.edu> wrote:
>>I think we are talking right past each other. Both Chrony and NTP
>>implement the clock discipline using a second-order feedback loop that
>chrony does not use a second-order feedback loop it is a high order, and
>variable order feedback loop. It remembers not just the slope and
>offset, as does ntp, but also past values of the errors. It is, as far
>as I can tell, stable ( poles in the lower have complex t plane.)
>The variable order also makes it non-linear.
>The high order and the non-linearity both make it very different from
>>can minimize error in both time and frequency, although each uses a
>>different loop filter. Chrony uses a least-squares technique; NTP uses a
>>traditional phase-lock loop. The response of these loops is
>>characterized by risetime and overshoot, or alternatively time constant
>>and damping factor. If Chrony were designed to have similar risetime and
>>overshoot characteristics and equivalent time constant, when operated
>>under the same conditions (trace 1) it will perform in a manner similar
>>to NTP. That was and is my claim.
>questions mailing list
>questions at lists.ntp.org
More information about the questions