Re: [chrony-users] Best way to force clock step at shutdown

[ Thread Index | Date Index | More chrony.tuxfamily.org/chrony-users Archives ]


On Tue, 12 Jan 2016, Hector Oron wrote:

Hello,

2016-01-12 14:33 GMT+01:00 Miroslav Lichvar <mlichvar@xxxxxxxxxx>:

How long ago was the clock set to this date? If chronyd hadn't had a
chance to make new measurements in that interval, the makestep command
would not fix the offset as chronyd would still think the date is
correct. It would be useful to see the output from chronyc tracking
and chronyc sources before the makestep command.

In a recently rebooted system (with an old date):

$ sudo chronyc -a
[sudo] password for desktop:
chrony version 1.30
Copyright (C) 1997-2003, 2007, 2009-2014 Richard P. Curnow and others
chrony comes with ABSOLUTELY NO WARRANTY.  This is free software, and
you are welcome to redistribute it under certain conditions.  See the
GNU General Public License version 2 for details.

200 OK

chronyc> activity
200 OK
4 sources online
0 sources offline
0 sources doing burst (return to online)
0 sources doing burst (return to offline)
0 sources with unknown address

chronyc> tracking
Reference ID    : 127.127.1.1 ()
Stratum         : 10
Ref time (UTC)  : Mon Nov 23 08:35:50 2015
System time     : 0.000000000 seconds slow of NTP time
Last offset     : +0.000000000 seconds
RMS offset      : 0.000000000 seconds
Frequency       : 0.930 ppm slow
Residual freq   : +0.000 ppm
Skew            : 0.000 ppm
Root delay      : 0.000000 seconds
Root dispersion : 0.000001 seconds
Update interval : 0.0 seconds
Leap status     : Not synchronised

You still have not gotten rid of that "local" clock. Please do. (Note that the
above indictes that chrony has not done anything yet to the system clock.)


chronyc> sources
210 Number of sources = 4
MS Name/IP address         Stratum Poll Reach LastRx Last sample
===============================================================================
^? der.beste.tiger.ist.sidne     2   8     1    69  -72527m[-72527m] +/-   41ms
^? ns3.customer-resolver.net     2   8     1    74  -72527m[-72527m] +/-   42ms
^? net2.uni-paderborn.de         1   8     1    74  -72527m[-72527m] +/-   29ms
^? trabant.uid0.hu               4   8     1    74  -72527m[-72527m] +/-   19ms

Which this confirms. This says that it has only sent out one packet to eachof
those servers. (Reach shifts left the current bits in reach and puts in a 1
bit(successful) or 0(unsuccessful) for each packet sent to that server.


chronyc> makestep

chrony does NOT have any data for you to make a step yet. There is no time.
You either have to run burst for it to get enough data (burst 3/5 for example)
or wait longer for at least three successful packets (reach 7)


200 OK

chronyc> tracking
Reference ID    : 127.127.1.1 ()
Stratum         : 10
Ref time (UTC)  : Mon Nov 23 08:39:06 2015
System time     : 0.000000000 seconds slow of NTP time
Last offset     : +0.000000000 seconds
RMS offset      : 0.000000000 seconds
Frequency       : 0.930 ppm slow
Residual freq   : +0.000 ppm
Skew            : 0.000 ppm
Root delay      : 0.000000 seconds
Root dispersion : 0.000001 seconds
Update interval : 0.0 seconds
Leap status     : Not synchronised



If I wait >17 minutes for chronyd to collect measurements results and
do a makestep, it does not seem to bring time to actual either.
activity command reports sources are online.

But they may well not yet have collected enough data to figure out what the
time is. Reach at least 7 and at least one of the sources ^* not ^?

At the moment the only reliable way I found so far is to stop chronyd
and run it manually to emulate ntpdate behaviour as recommended in
chronyd -q 'server pool.ntp.org iburst'

Why would you want to emulate ntpdate behaviour. But if you do, then that is
the way to do it.

Regards,
--
Héctor Orón  -.. . -... .. .- -.   -.. . ...- . .-.. --- .--. . .-.

--
To unsubscribe email chrony-users-request@xxxxxxxxxxxxxxxxxxxx
with "unsubscribe" in the subject.
For help email chrony-users-request@xxxxxxxxxxxxxxxxxxxx
with "help" in the subject.
Trouble?  Email listmaster@xxxxxxxxxxxxxxxxxxxx.


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/