How is ntpd data used -
Bob Goodwin
bobgoodwin at att.net
Sat Nov 6 17:34:07 UTC 2004
Rodolfo J. Paiz wrote:
>On Sat, 2004-11-06 at 08:12 -0500, Bob Goodwin wrote:
>
>
>>Markku Kolkka wrote:
>>
>>
>>
>>>You should insert a few minutes of delay between those two calls
>>>to let the ntp daemon to work.
>>>
>>>
>>>
>>>
>>Yes I do that -
>>
>>~ cat ./tsync
>>
>>service ntpd restart
>>
>>sleep 5
>>
>>ntpq -p
>>
>>
>>
>
>Note Markku said "minutes", not 5 seconds. Since ntpd wants very high
>precision, it does not make abrupt changes to a system. IMHO, you should
>wait at least 15 *minutes* for ntpd to begin settling down before you
>query it.
>
>Cheers,
>
>
>
Yes I noticed what he said but interpreted "a few minutes" as "wait a
moment."
I found that it's necessary to wait a short time, 5 seconds works for
me, or
else ntpq does not have time to collect the data and returns an empty
table as in the trial below :
~ ./tsyncx
Shutting down ntpd: [ OK ]
ntpd: Synchronizing with time server: [ OK ]
Starting ntpd: [ OK ]
remote refid st t when poll reach delay offset
jitter
==============================================================================
ntp-1.cns.vt.ed .INIT. 16 u - 64 0 0.000 0.000
4000.00
ntp-4.cns.vt.ed .INIT. 16 u - 64 0 0.000 0.000
4000.00
ntp2.jrc.us .INIT. 16 u - 64 0 0.000 0.000
4000.00
ntp1.jrc.us .INIT. 16 u - 64 0 0.000 0.000
4000.00
Initially I needed ntpq as assurance that things were working. I now have
confidence in it and will try a longer period, perhaps 1000 seconds?
However, even with the 5 seconds I believe it's correcting the clock? Or
does running ntpq upset things somehow? Result in less than optimum
correction?
Thanks for the advice.
Bob Goodwin
More information about the fedora-list
mailing list