Discussion:
[chrony-users] How to avoid oversteering
Ariel Garcia
2018-02-05 19:02:25 UTC
Permalink
Hello,

i am trying to get Chrony 3.2 running without stepping the clock, but i
find that it oversteers by a huge amount. I observe that it starts driving
the system clock to the right value, but then moves it more that the
initial offset in the opposite direction, and starts "oscillating".

I rebooted to make sure the system clock runs at the "default" speed
initially, having previously set the RTC ~10s off from the correct time
for testing. After chrony started it reported:
System time : 10.891304016 seconds slow of NTP time
After ~ 10 minutes running it was already:
System time : 2.529696226 seconds slow of NTP time
but then after ~20 minutes it was already in the opposite direction:
System time : 12.160170555 seconds fast of NTP time
After one hour running it is worse than at the beginning:
System time : 16.009445190 seconds slow of NTP time

What am i doing wrong, am i having the wrong expectation, or could
it be a hardware or a configuration issue?
(the drift values shown above are consistent with the device's RTC
--which is not being adjusted-- and an external PC)

I've tried to collect all details below,
thanks in advance for any hints/help!!
Ariel


================================================================
Running on a BeagleBone black-similar board, with an AM335X CPU.

My configuration was chosen as simple as possible to start:
--------------------------------
pool de.pool.ntp.org minpoll 4
makestep 3600 3
logchange 0.05
cmdallow 127.0.0.1
bindcmdaddress /run/chrony/chronyd.sock
pidfile /run/chrony/chronyd.pid
-------------------------------

Of course i made sure there is no other NTP daemon running.
These are all running processes (only deleted my open ssh connections)
--------------------------------
1 ? Ss 0:10 /sbin/init
978 ? Ss 0:03 /usr/sbin/rngd -f
985 ? Ss 0:04 /lib/systemd/systemd-journald
1773 ? Ss 0:00 /lib/systemd/systemd-udevd
1805 ttyO0 Ss+ 0:00 /sbin/agetty --keep-baud 115200 38400 9600 ttyO0 vt220
1812 ? Ss 0:00 /usr/bin/dbus-daemon --system --address=systemd: --nofork --nopidfile --systemd-activation
1813 ? Ss 0:00 /usr/sbin/crond -b
1827 ? Ss 0:00 /lib/systemd/systemd-networkd
1834 ? Ss 0:00 /lib/systemd/systemd-resolved
15344 ? S 0:00 /usr/sbin/chronyd -4 -f /etc/chrony/chrony.conf
--------------------------------

The servers are reachable and seem ok:
--------------------------------
$ chronyc -n sources
210 Number of sources = 4
MS Name/IP address Stratum Poll Reach LastRx Last sample
===============================================================================
^- 172.104.239.150 2 4 377 3 -1158ms[-1158ms] +/- 58ms
^- 138.201.135.108 2 4 377 4 -1057ms[-1057ms] +/- 47ms
^* 195.34.187.132 2 4 377 14 +17ms[-1527ms] +/- 28ms
^- 5.9.78.71 2 4 377 13 -142ms[ -142ms] +/- 50ms

$ chronyc -n sourcestats
210 Number of sources = 4
Name/IP Address NP NR Span Frequency Freq Skew Offset Std Dev
==============================================================================
172.104.239.150 6 3 75 -103422 1668.695 -1033ms 14ms
138.201.135.108 6 3 75 -103305 1165.815 -1020ms 11ms
195.34.187.132 6 3 75 -103052 2391.831 -1021ms 15ms
5.9.78.71 6 3 75 -102973 2085.425 -1017ms 14ms
--------------------------------

The logs show
---------------------------------
Feb 05 17:18:22 BBx systemd[1]: Starting NTP client/server...
Feb 05 17:18:22 BBx chronyd[15344]: chronyd version 3.2 starting (+CMDMON +NTP +REFCLOCK +RTC +PRIVDROP -SCFILTER -SECHASH -SIGND +ASYNCDNS +IPV6 -DEBUG)
Feb 05 17:18:22 BBx chronyd[15344]: Initial frequency 42.124 ppm
Feb 05 17:18:22 BBx systemd[1]: Started NTP client/server.
Feb 05 17:18:55 BBx chronyd[15344]: Selected source 129.70.132.35
Feb 05 17:18:56 BBx chronyd[15344]: System clock wrong by 11.087803 seconds, adjustment started
Feb 05 17:19:11 BBx chronyd[15344]: Can't synchronise: no majority
Feb 05 17:19:12 BBx chronyd[15344]: Selected source 129.70.132.35
Feb 05 17:19:12 BBx chronyd[15344]: System clock wrong by 1.096591 seconds, adjustment started
Feb 05 17:19:27 BBx chronyd[15344]: Selected source 138.201.135.108
Feb 05 17:19:27 BBx chronyd[15344]: System clock wrong by 0.943644 seconds, adjustment started
Feb 05 17:19:43 BBx chronyd[15344]: System clock wrong by 1.241887 seconds, adjustment started
...
(lots or similar lines, but always the system clock is reported to be wrong
by +2 to -2 seconds, never by the amount shown by "chronyc tracking")
...
---------------------------------

The tracking data at different times:
---------------------------------
$ chronyc tracking
Reference ID : 81468423 (stratum2-2.NTP.TechFak.NET)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:19:05 2018
System time : 10.891304016 seconds slow of NTP time
Last offset : -11.087802887 seconds
RMS offset : 11.087802887 seconds
Frequency : 42.124 ppm fast
Residual freq : +1.113 ppm
Skew : 1000000.000 ppm
Root delay : 0.037714522 seconds
Root dispersion : 3.768865824 seconds
Update interval : 0.0 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : 8AC9876C (srv23.globale-gruppe.com)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:19:37 2018
System time : 9.804729462 seconds slow of NTP time
Last offset : -0.943643808 seconds
RMS offset : 0.943643808 seconds
Frequency : 42.124 ppm fast
Residual freq : -41046.902 ppm
Skew : 1000000.000 ppm
Root delay : 0.033498995 seconds
Root dispersion : 12.330061913 seconds
Update interval : 14.3 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : 81468423 (stratum2-2.NTP.TechFak.NET)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:24:13 2018
System time : 9.454131126 seconds slow of NTP time
Last offset : +0.030433958 seconds
RMS offset : 0.640062451 seconds
Frequency : 90705.453 ppm slow
Residual freq : +86.611 ppm
Skew : 1054.889 ppm
Root delay : 0.035278354 seconds
Root dispersion : 0.017751774 seconds
Update interval : 16.1 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : 81468423 (stratum2-2.NTP.TechFak.NET)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:31:07 2018
System time : 2.529696226 seconds slow of NTP time
Last offset : +0.029113885 seconds
RMS offset : 0.166937038 seconds
Frequency : 77410.445 ppm slow
Residual freq : +1074.334 ppm
Skew : 1991.644 ppm
Root delay : 0.035502460 seconds
Root dispersion : 0.027657172 seconds
Update interval : 15.8 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : 8AC9876C (srv23.globale-gruppe.com)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:37:24 2018
System time : 6.902931690 seconds fast of NTP time
Last offset : +0.189766780 seconds
RMS offset : 1.233845592 seconds
Frequency : 108520.094 ppm fast
Residual freq : +12504.339 ppm
Skew : 30318.885 ppm
Root delay : 0.034667145 seconds
Root dispersion : 0.311530590 seconds
Update interval : 16.1 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : 81468423 (stratum2-2.NTP.TechFak.NET)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:45:10 2018
System time : 13.315183640 seconds fast of NTP time
Last offset : -0.028802348 seconds
RMS offset : 0.300014675 seconds
Frequency : 106800.570 ppm fast
Residual freq : -74.106 ppm
Skew : 1022.886 ppm
Root delay : 0.034821544 seconds
Root dispersion : 0.017649684 seconds
Update interval : 16.2 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : C322BB84 (powered.by.inet.de)
Stratum : 3
Ref time (UTC) : Mon Feb 05 18:06:29 2018
System time : 4.486146450 seconds slow of NTP time
Last offset : -0.437962651 seconds
RMS offset : 1.165199637 seconds
Frequency : 19659.746 ppm slow
Residual freq : -14884.478 ppm
Skew : 39623.336 ppm
Root delay : 0.025750067 seconds
Root dispersion : 0.237240255 seconds
Update interval : 3.7 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : C322BB84 (powered.by.inet.de)
Stratum : 3
Ref time (UTC) : Mon Feb 05 18:19:55 2018
System time : 16.009445190 seconds slow of NTP time
Last offset : +0.026499212 seconds
RMS offset : 0.694284379 seconds
Frequency : 102772.656 ppm slow
Residual freq : +110.795 ppm
Skew : 1070.995 ppm
Root delay : 0.027395297 seconds
Root dispersion : 0.030097129 seconds
Update interval : 16.3 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : AC68EF96 (watch.no-such-agency.net)
Stratum : 3
Ref time (UTC) : Mon Feb 05 18:52:14 2018
System time : 17.909534454 seconds fast of NTP time
Last offset : -0.021534055 seconds
RMS offset : 0.502140403 seconds
Frequency : 106267.859 ppm fast
Residual freq : -85.290 ppm
Skew : 1018.805 ppm
Root delay : 0.025392590 seconds
Root dispersion : 0.026234277 seconds
Update interval : 13.1 seconds
Leap status : Normal
---------------------------------
--
To unsubscribe email chrony-users-***@chrony.tuxfamily.org
with "unsubscribe" in the subject.
For help email chrony-users-***@chrony.tuxfamily.org
with "help" in the subject.
Trouble? Email ***@chrony.tuxfamily.org.
Bill Unruh
2018-02-05 20:24:13 UTC
Permalink
chronyd should not be doing that. It has a very efficient way of determining
what the correct rate should be, and uses an extra drift to drive the offset
to zero.


Is this on real hardware on a virtual machine? Chrony should not be run on
virtual machines, because the timing on those is a mess. Their internal clocks
are not regular.

Alternatively it could be a severe hardware issue, or you could be running the
system on a tickless clock.
Post by Ariel Garcia
Hello,
i am trying to get Chrony 3.2 running without stepping the clock, but i
find that it oversteers by a huge amount. I observe that it starts driving
the system clock to the right value, but then moves it more that the
initial offset in the opposite direction, and starts "oscillating".
I rebooted to make sure the system clock runs at the "default" speed
initially, having previously set the RTC ~10s off from the correct time
System time : 10.891304016 seconds slow of NTP time
System time : 2.529696226 seconds slow of NTP time
System time : 12.160170555 seconds fast of NTP time
System time : 16.009445190 seconds slow of NTP time
What am i doing wrong, am i having the wrong expectation, or could
it be a hardware or a configuration issue?
(the drift values shown above are consistent with the device's RTC
--which is not being adjusted-- and an external PC)
I've tried to collect all details below,
thanks in advance for any hints/help!!
Ariel
================================================================
Running on a BeagleBone black-similar board, with an AM335X CPU.
--------------------------------
pool de.pool.ntp.org minpoll 4
makestep 3600 3
logchange 0.05
cmdallow 127.0.0.1
bindcmdaddress /run/chrony/chronyd.sock
pidfile /run/chrony/chronyd.pid
-------------------------------
Of course i made sure there is no other NTP daemon running.
These are all running processes (only deleted my open ssh connections)
--------------------------------
1 ? Ss 0:10 /sbin/init
978 ? Ss 0:03 /usr/sbin/rngd -f
985 ? Ss 0:04 /lib/systemd/systemd-journald
1773 ? Ss 0:00 /lib/systemd/systemd-udevd
1805 ttyO0 Ss+ 0:00 /sbin/agetty --keep-baud 115200 38400 9600 ttyO0 vt220
1812 ? Ss 0:00 /usr/bin/dbus-daemon --system --address=systemd: --nofork --nopidfile --systemd-activation
1813 ? Ss 0:00 /usr/sbin/crond -b
1827 ? Ss 0:00 /lib/systemd/systemd-networkd
1834 ? Ss 0:00 /lib/systemd/systemd-resolved
15344 ? S 0:00 /usr/sbin/chronyd -4 -f /etc/chrony/chrony.conf
--------------------------------
--------------------------------
$ chronyc -n sources
210 Number of sources = 4
MS Name/IP address Stratum Poll Reach LastRx Last sample
===============================================================================
^- 172.104.239.150 2 4 377 3 -1158ms[-1158ms] +/- 58ms
^- 138.201.135.108 2 4 377 4 -1057ms[-1057ms] +/- 47ms
^* 195.34.187.132 2 4 377 14 +17ms[-1527ms] +/- 28ms
^- 5.9.78.71 2 4 377 13 -142ms[ -142ms] +/- 50ms
$ chronyc -n sourcestats
210 Number of sources = 4
Name/IP Address NP NR Span Frequency Freq Skew Offset Std Dev
==============================================================================
172.104.239.150 6 3 75 -103422 1668.695 -1033ms 14ms
138.201.135.108 6 3 75 -103305 1165.815 -1020ms 11ms
195.34.187.132 6 3 75 -103052 2391.831 -1021ms 15ms
5.9.78.71 6 3 75 -102973 2085.425 -1017ms 14ms
--------------------------------
The logs show
---------------------------------
Feb 05 17:18:22 BBx systemd[1]: Starting NTP client/server...
Feb 05 17:18:22 BBx chronyd[15344]: chronyd version 3.2 starting (+CMDMON +NTP +REFCLOCK +RTC +PRIVDROP -SCFILTER -SECHASH -SIGND +ASYNCDNS +IPV6 -DEBUG)
Feb 05 17:18:22 BBx chronyd[15344]: Initial frequency 42.124 ppm
Feb 05 17:18:22 BBx systemd[1]: Started NTP client/server.
Feb 05 17:18:55 BBx chronyd[15344]: Selected source 129.70.132.35
Feb 05 17:18:56 BBx chronyd[15344]: System clock wrong by 11.087803 seconds, adjustment started
Feb 05 17:19:11 BBx chronyd[15344]: Can't synchronise: no majority
Feb 05 17:19:12 BBx chronyd[15344]: Selected source 129.70.132.35
Feb 05 17:19:12 BBx chronyd[15344]: System clock wrong by 1.096591 seconds, adjustment started
Feb 05 17:19:27 BBx chronyd[15344]: Selected source 138.201.135.108
Feb 05 17:19:27 BBx chronyd[15344]: System clock wrong by 0.943644 seconds, adjustment started
Feb 05 17:19:43 BBx chronyd[15344]: System clock wrong by 1.241887 seconds, adjustment started
...
(lots or similar lines, but always the system clock is reported to be wrong
by +2 to -2 seconds, never by the amount shown by "chronyc tracking")
...
---------------------------------
---------------------------------
$ chronyc tracking
Reference ID : 81468423 (stratum2-2.NTP.TechFak.NET)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:19:05 2018
System time : 10.891304016 seconds slow of NTP time
Last offset : -11.087802887 seconds
RMS offset : 11.087802887 seconds
Frequency : 42.124 ppm fast
Residual freq : +1.113 ppm
Skew : 1000000.000 ppm
Root delay : 0.037714522 seconds
Root dispersion : 3.768865824 seconds
Update interval : 0.0 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : 8AC9876C (srv23.globale-gruppe.com)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:19:37 2018
System time : 9.804729462 seconds slow of NTP time
Last offset : -0.943643808 seconds
RMS offset : 0.943643808 seconds
Frequency : 42.124 ppm fast
Residual freq : -41046.902 ppm
Skew : 1000000.000 ppm
Root delay : 0.033498995 seconds
Root dispersion : 12.330061913 seconds
Update interval : 14.3 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : 81468423 (stratum2-2.NTP.TechFak.NET)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:24:13 2018
System time : 9.454131126 seconds slow of NTP time
Last offset : +0.030433958 seconds
RMS offset : 0.640062451 seconds
Frequency : 90705.453 ppm slow
Residual freq : +86.611 ppm
Skew : 1054.889 ppm
Root delay : 0.035278354 seconds
Root dispersion : 0.017751774 seconds
Update interval : 16.1 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : 81468423 (stratum2-2.NTP.TechFak.NET)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:31:07 2018
System time : 2.529696226 seconds slow of NTP time
Last offset : +0.029113885 seconds
RMS offset : 0.166937038 seconds
Frequency : 77410.445 ppm slow
Residual freq : +1074.334 ppm
Skew : 1991.644 ppm
Root delay : 0.035502460 seconds
Root dispersion : 0.027657172 seconds
Update interval : 15.8 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : 8AC9876C (srv23.globale-gruppe.com)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:37:24 2018
System time : 6.902931690 seconds fast of NTP time
Last offset : +0.189766780 seconds
RMS offset : 1.233845592 seconds
Frequency : 108520.094 ppm fast
Residual freq : +12504.339 ppm
Skew : 30318.885 ppm
Root delay : 0.034667145 seconds
Root dispersion : 0.311530590 seconds
Update interval : 16.1 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : 81468423 (stratum2-2.NTP.TechFak.NET)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:45:10 2018
System time : 13.315183640 seconds fast of NTP time
Last offset : -0.028802348 seconds
RMS offset : 0.300014675 seconds
Frequency : 106800.570 ppm fast
Residual freq : -74.106 ppm
Skew : 1022.886 ppm
Root delay : 0.034821544 seconds
Root dispersion : 0.017649684 seconds
Update interval : 16.2 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : C322BB84 (powered.by.inet.de)
Stratum : 3
Ref time (UTC) : Mon Feb 05 18:06:29 2018
System time : 4.486146450 seconds slow of NTP time
Last offset : -0.437962651 seconds
RMS offset : 1.165199637 seconds
Frequency : 19659.746 ppm slow
Residual freq : -14884.478 ppm
Skew : 39623.336 ppm
Root delay : 0.025750067 seconds
Root dispersion : 0.237240255 seconds
Update interval : 3.7 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : C322BB84 (powered.by.inet.de)
Stratum : 3
Ref time (UTC) : Mon Feb 05 18:19:55 2018
System time : 16.009445190 seconds slow of NTP time
Last offset : +0.026499212 seconds
RMS offset : 0.694284379 seconds
Frequency : 102772.656 ppm slow
Residual freq : +110.795 ppm
Skew : 1070.995 ppm
Root delay : 0.027395297 seconds
Root dispersion : 0.030097129 seconds
Update interval : 16.3 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : AC68EF96 (watch.no-such-agency.net)
Stratum : 3
Ref time (UTC) : Mon Feb 05 18:52:14 2018
System time : 17.909534454 seconds fast of NTP time
Last offset : -0.021534055 seconds
RMS offset : 0.502140403 seconds
Frequency : 106267.859 ppm fast
Residual freq : -85.290 ppm
Skew : 1018.805 ppm
Root delay : 0.025392590 seconds
Root dispersion : 0.026234277 seconds
Update interval : 13.1 seconds
Leap status : Normal
---------------------------------
--
with "unsubscribe" in the subject.
with "help" in the subject.
--
To unsubscribe email chrony-users-***@chrony.tuxfamily.org
with "unsubscribe" in the subject.
For help email chrony-users-***@chrony.tuxfamily.org
with "help" in the subject.
Trouble? Email ***@chrony.tuxfamily.org.
Ariel Garcia
2018-02-05 21:22:50 UTC
Permalink
Post by Bill Unruh
chronyd should not be doing that. It has a very efficient way of determining
what the correct rate should be, and uses an extra drift to drive the
offset to zero.
Is this on real hardware on a virtual machine? Chrony should not be run on
virtual machines, because the timing on those is a mess. Their internal
clocks are not regular.
thanks for your fast answer!
It is definitely NOTt a VM, but an ARM board (similar to BeagleBones black)
Post by Bill Unruh
Alternatively it could be a severe hardware issue
the system clock runs fine if left alone!! It drifts a few seconds per day, but
that's it.
Chrony changes the clock frequency enormously when it starts "correcting"
it... I can see that comparing system-clock and RTC times both with and
without chrony.
Post by Bill Unruh
or you could be running the system on a tickless clock.
That is a good hint! that is a kernel config option right?
Post by Bill Unruh
Post by Ariel Garcia
Hello,
i am trying to get Chrony 3.2 running without stepping the clock, but i
find that it oversteers by a huge amount. I observe that it starts driving
the system clock to the right value, but then moves it more that the
initial offset in the opposite direction, and starts "oscillating".
I rebooted to make sure the system clock runs at the "default" speed
initially, having previously set the RTC ~10s off from the correct time
System time : 10.891304016 seconds slow of NTP time
System time : 2.529696226 seconds slow of NTP time
System time : 12.160170555 seconds fast of NTP time
System time : 16.009445190 seconds slow of NTP time
What am i doing wrong, am i having the wrong expectation, or could
it be a hardware or a configuration issue?
(the drift values shown above are consistent with the device's RTC
--which is not being adjusted-- and an external PC)
I've tried to collect all details below,
thanks in advance for any hints/help!!
Ariel
================================================================
Running on a BeagleBone black-similar board, with an AM335X CPU.
--------------------------------
pool de.pool.ntp.org minpoll 4
makestep 3600 3
logchange 0.05
cmdallow 127.0.0.1
bindcmdaddress /run/chrony/chronyd.sock
pidfile /run/chrony/chronyd.pid
-------------------------------
Of course i made sure there is no other NTP daemon running.
These are all running processes (only deleted my open ssh connections)
--------------------------------
1 ? Ss 0:10 /sbin/init
978 ? Ss 0:03 /usr/sbin/rngd -f
985 ? Ss 0:04 /lib/systemd/systemd-journald
1773 ? Ss 0:00 /lib/systemd/systemd-udevd
1805 ttyO0 Ss+ 0:00 /sbin/agetty --keep-baud 115200 38400 9600 ttyO0
vt220 1812 ? Ss 0:00 /usr/bin/dbus-daemon --system
--address=systemd: --nofork --nopidfile --systemd-activation 1813 ?
Ss 0:00 /usr/sbin/crond -b
1827 ? Ss 0:00 /lib/systemd/systemd-networkd
1834 ? Ss 0:00 /lib/systemd/systemd-resolved
15344 ? S 0:00 /usr/sbin/chronyd -4 -f /etc/chrony/chrony.conf
--------------------------------
--------------------------------
$ chronyc -n sources
210 Number of sources = 4
MS Name/IP address Stratum Poll Reach LastRx Last sample
==========================================================================
===== ^- 172.104.239.150 2 4 377 3 -1158ms[-1158ms]
+/- 58ms ^- 138.201.135.108 2 4 377 4
-1057ms[-1057ms] +/- 47ms ^* 195.34.187.132 2 4 377
14 +17ms[-1527ms] +/- 28ms ^- 5.9.78.71 2 4
377 13 -142ms[ -142ms] +/- 50ms
$ chronyc -n sourcestats
210 Number of sources = 4
Name/IP Address NP NR Span Frequency Freq Skew Offset Std Dev
=========================================================================
===== 172.104.239.150 6 3 75 -103422 1668.695
-1033ms 14ms 138.201.135.108 6 3 75 -103305
1165.815 -1020ms 11ms 195.34.187.132 6 3 75
-103052 2391.831 -1021ms 15ms 5.9.78.71 6 3
75 -102973 2085.425 -1017ms 14ms
--------------------------------
The logs show
---------------------------------
Feb 05 17:18:22 BBx systemd[1]: Starting NTP client/server...
Feb 05 17:18:22 BBx chronyd[15344]: chronyd version 3.2 starting (+CMDMON
+NTP +REFCLOCK +RTC +PRIVDROP -SCFILTER -SECHASH -SIGND +ASYNCDNS +IPV6
-DEBUG) Feb 05 17:18:22 BBx chronyd[15344]: Initial frequency 42.124 ppm
Feb 05 17:18:22 BBx systemd[1]: Started NTP client/server.
Feb 05 17:18:55 BBx chronyd[15344]: Selected source 129.70.132.35
Feb 05 17:18:56 BBx chronyd[15344]: System clock wrong by 11.087803
seconds, adjustment started Feb 05 17:19:11 BBx chronyd[15344]: Can't
synchronise: no majority Feb 05 17:19:12 BBx chronyd[15344]: Selected
source 129.70.132.35
Feb 05 17:19:12 BBx chronyd[15344]: System clock wrong by 1.096591
seconds, adjustment started Feb 05 17:19:27 BBx chronyd[15344]: Selected
source 138.201.135.108 Feb 05 17:19:27 BBx chronyd[15344]: System clock
wrong by 0.943644 seconds, adjustment started Feb 05 17:19:43 BBx
chronyd[15344]: System clock wrong by 1.241887 seconds, adjustment
started ...
(lots or similar lines, but always the system clock is reported to be wrong
by +2 to -2 seconds, never by the amount shown by "chronyc tracking")
...
---------------------------------
---------------------------------
$ chronyc tracking
Reference ID : 81468423 (stratum2-2.NTP.TechFak.NET)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:19:05 2018
System time : 10.891304016 seconds slow of NTP time
Last offset : -11.087802887 seconds
RMS offset : 11.087802887 seconds
Frequency : 42.124 ppm fast
Residual freq : +1.113 ppm
Skew : 1000000.000 ppm
Root delay : 0.037714522 seconds
Root dispersion : 3.768865824 seconds
Update interval : 0.0 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : 8AC9876C (srv23.globale-gruppe.com)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:19:37 2018
System time : 9.804729462 seconds slow of NTP time
Last offset : -0.943643808 seconds
RMS offset : 0.943643808 seconds
Frequency : 42.124 ppm fast
Residual freq : -41046.902 ppm
Skew : 1000000.000 ppm
Root delay : 0.033498995 seconds
Root dispersion : 12.330061913 seconds
Update interval : 14.3 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : 81468423 (stratum2-2.NTP.TechFak.NET)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:24:13 2018
System time : 9.454131126 seconds slow of NTP time
Last offset : +0.030433958 seconds
RMS offset : 0.640062451 seconds
Frequency : 90705.453 ppm slow
Residual freq : +86.611 ppm
Skew : 1054.889 ppm
Root delay : 0.035278354 seconds
Root dispersion : 0.017751774 seconds
Update interval : 16.1 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : 81468423 (stratum2-2.NTP.TechFak.NET)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:31:07 2018
System time : 2.529696226 seconds slow of NTP time
Last offset : +0.029113885 seconds
RMS offset : 0.166937038 seconds
Frequency : 77410.445 ppm slow
Residual freq : +1074.334 ppm
Skew : 1991.644 ppm
Root delay : 0.035502460 seconds
Root dispersion : 0.027657172 seconds
Update interval : 15.8 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : 8AC9876C (srv23.globale-gruppe.com)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:37:24 2018
System time : 6.902931690 seconds fast of NTP time
Last offset : +0.189766780 seconds
RMS offset : 1.233845592 seconds
Frequency : 108520.094 ppm fast
Residual freq : +12504.339 ppm
Skew : 30318.885 ppm
Root delay : 0.034667145 seconds
Root dispersion : 0.311530590 seconds
Update interval : 16.1 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : 81468423 (stratum2-2.NTP.TechFak.NET)
Stratum : 3
Ref time (UTC) : Mon Feb 05 17:45:10 2018
System time : 13.315183640 seconds fast of NTP time
Last offset : -0.028802348 seconds
RMS offset : 0.300014675 seconds
Frequency : 106800.570 ppm fast
Residual freq : -74.106 ppm
Skew : 1022.886 ppm
Root delay : 0.034821544 seconds
Root dispersion : 0.017649684 seconds
Update interval : 16.2 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : C322BB84 (powered.by.inet.de)
Stratum : 3
Ref time (UTC) : Mon Feb 05 18:06:29 2018
System time : 4.486146450 seconds slow of NTP time
Last offset : -0.437962651 seconds
RMS offset : 1.165199637 seconds
Frequency : 19659.746 ppm slow
Residual freq : -14884.478 ppm
Skew : 39623.336 ppm
Root delay : 0.025750067 seconds
Root dispersion : 0.237240255 seconds
Update interval : 3.7 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : C322BB84 (powered.by.inet.de)
Stratum : 3
Ref time (UTC) : Mon Feb 05 18:19:55 2018
System time : 16.009445190 seconds slow of NTP time
Last offset : +0.026499212 seconds
RMS offset : 0.694284379 seconds
Frequency : 102772.656 ppm slow
Residual freq : +110.795 ppm
Skew : 1070.995 ppm
Root delay : 0.027395297 seconds
Root dispersion : 0.030097129 seconds
Update interval : 16.3 seconds
Leap status : Normal
---------------------------------
$ chronyc tracking
Reference ID : AC68EF96 (watch.no-such-agency.net)
Stratum : 3
Ref time (UTC) : Mon Feb 05 18:52:14 2018
System time : 17.909534454 seconds fast of NTP time
Last offset : -0.021534055 seconds
RMS offset : 0.502140403 seconds
Frequency : 106267.859 ppm fast
Residual freq : -85.290 ppm
Skew : 1018.805 ppm
Root delay : 0.025392590 seconds
Root dispersion : 0.026234277 seconds
Update interval : 13.1 seconds
Leap status : Normal
---------------------------------
--
To unsubscribe email chrony-users-***@chrony.tuxfamily.org
with "unsubscribe" in the subject.
For help email chrony-users-***@chrony.tuxfamily.org
with "help" in the subject.
Trouble? Email ***@chrony.tuxfamily.org.
Ariel Garcia
2018-02-05 21:27:08 UTC
Permalink
Post by Bill Unruh
Alternatively it could be a severe hardware issue, or you could be running
the system on a tickless clock.
# zcat /proc/config.gz | grep HZ
CONFIG_NO_HZ_COMMON=y
CONFIG_NO_HZ_IDLE=y
CONFIG_NO_HZ=y
CONFIG_HZ_FIXED=0
CONFIG_HZ_100=y
CONFIG_HZ=100

i guess the CONFIG_NO_HZ=y setting is what you mean, right?
--
To unsubscribe email chrony-users-***@chrony.tuxfamily.org
with "unsubscribe" in the subject.
For help email chrony-users-***@chrony.tuxfamily.org
with "help" in the subject.
Trouble? Email ***@chrony.tuxfamily.org.
Bill Unruh
2018-02-05 23:03:59 UTC
Permalink
William G. Unruh __| Canadian Institute for|____ Tel: +1(604)822-3273
Physics&Astronomy _|___ Advanced Research _|____ Fax: +1(604)822-5324
UBC, Vancouver,BC _|_ Program in Cosmology |____ ***@physics.ubc.ca
Canada V6T 1Z1 ____|____ and Gravity ______|_ www.theory.physics.ubc.ca/
Post by Ariel Garcia
Post by Bill Unruh
Alternatively it could be a severe hardware issue, or you could be running
the system on a tickless clock.
# zcat /proc/config.gz | grep HZ
CONFIG_NO_HZ_COMMON=y
CONFIG_NO_HZ_IDLE=y
CONFIG_NO_HZ=y
CONFIG_HZ_FIXED=0
CONFIG_HZ_100=y
CONFIG_HZ=100
i guess the CONFIG_NO_HZ=y setting is what you mean, right?
I really do not understand all of those options properly. I am also confused
at both CONFIG_NO_HZ=y and CONFIG_HZ_100=y but that is probably just another
aspect of my confusion.
Post by Ariel Garcia
--
with "unsubscribe" in the subject.
with "help" in the subject.
--
To unsubscribe email chrony-users-***@chrony.tuxfamily.org
with "unsubscribe" in the subject.
For help email chrony-users-***@chrony.tuxfamily.org
with "help" in the subject.
Trouble? Email ***@chrony.tuxfamily.org.
Charles Muggen
2018-02-06 16:57:45 UTC
Permalink
There is no config.gz file in the /proc directory.
Sent: Monday, February 05, 2018 at 4:27 PM
Subject: Re: [chrony-users] How to avoid oversteering
Post by Bill Unruh
Alternatively it could be a severe hardware issue, or you could be running
the system on a tickless clock.
# zcat /proc/config.gz | grep HZ
CONFIG_NO_HZ_COMMON=y
CONFIG_NO_HZ_IDLE=y
CONFIG_NO_HZ=y
CONFIG_HZ_FIXED=0
CONFIG_HZ_100=y
CONFIG_HZ=100
i guess the CONFIG_NO_HZ=y setting is what you mean, right?
--
with "unsubscribe" in the subject.
with "help" in the subject.
--
To unsubscribe email chrony-users-***@chrony.tuxfamily.org
with "unsubscribe" in the subject.
For help email chrony-users-***@chrony.tuxfamily.org
with "help" in the subject.
Trouble? Email ***@chrony.tuxfamily.org.
Ariel Garcia
2018-02-06 17:07:36 UTC
Permalink
Post by Charles Muggen
There is no config.gz file in the /proc directory.
well, it depends how you (or your distribution) compiled the kernel...

The option is/are:

CONFIG_IKCONFIG=y
CONFIG_IKCONFIG_PROC=y

inside "general Setup"
--
To unsubscribe email chrony-users-***@chrony.tuxfamily.org
with "unsubscribe" in the subject.
For help email chrony-users-***@chrony.tuxfamily.org
with "help" in the subject.
Trouble? Email ***@chrony.tuxfamily.org.
Miroslav Lichvar
2018-02-06 08:25:45 UTC
Permalink
Post by Ariel Garcia
Hello,
i am trying to get Chrony 3.2 running without stepping the clock, but i
find that it oversteers by a huge amount. I observe that it starts driving
the system clock to the right value, but then moves it more that the
initial offset in the opposite direction, and starts "oscillating".
This looks like a broken system clock. chronyd is telling the kernel
to slow down or speed up the clock, but it doesn't happen.

What kernel version is the board running? There was a bug which caused
issues like that and it was fixed few years ago. IIRC it was specific
to 32-bit platforms.
--
Miroslav Lichvar
--
To unsubscribe email chrony-users-***@chrony.tuxfamily.org
with "unsubscribe" in the subject.
For help email chrony-users-***@chrony.tuxfamily.org
with "help" in the subject.
Trouble? Email ***@chrony.tuxfamily.org.
Ariel Garcia
2018-02-06 11:10:50 UTC
Permalink
Post by Miroslav Lichvar
Post by Ariel Garcia
i am trying to get Chrony 3.2 running without stepping the clock, but i
find that it oversteers by a huge amount. I observe that it starts driving
the system clock to the right value, but then moves it more that the
initial offset in the opposite direction, and starts "oscillating".
This looks like a broken system clock. chronyd is telling the kernel
to slow down or speed up the clock, but it doesn't happen.
What kernel version is the board running? There was a bug which caused
issues like that and it was fixed few years ago. IIRC it was specific
to 32-bit platforms.
Thanks for you feedback!
You probably mean this one?
https://bugzilla.redhat.com/show_bug.cgi?id=1188074

I'm running 4.2.8 32bit (embedded device...)
I will recompile chrony adding some debugging for the frequency it tries to
set, my impression is also that the clock stays always at plus or minus the
max frequency drift, once chrony starts to touch it.
Post by Miroslav Lichvar
Alternatively it could be a severe hardware issue, or you could be running
the system on a tickless clock.
i recompiled the kernel with ticks (and without power governors/frequency
drivers, just performance) but it did not help.

Thanks!
--
To unsubscribe email chrony-users-***@chrony.tuxfamily.org
with "unsubscribe" in the subject.
For help email chrony-users-***@chrony.tuxfamily.org
with "help" in the subject.
Trouble? Email ***@chrony.tuxfamily.org.
Miroslav Lichvar
2018-02-06 11:26:05 UTC
Permalink
Post by Ariel Garcia
Post by Miroslav Lichvar
What kernel version is the board running? There was a bug which caused
issues like that and it was fixed few years ago. IIRC it was specific
to 32-bit platforms.
Thanks for you feedback!
You probably mean this one?
https://bugzilla.redhat.com/show_bug.cgi?id=1188074
No, I think it's this one:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=2619d7e9c92d524cb155ec89fd72875321512e5b
Post by Ariel Garcia
I'm running 4.2.8 32bit (embedded device...)
The fix was included in 4.3, so it might be the bug you are hitting.
--
Miroslav Lichvar
--
To unsubscribe email chrony-users-***@chrony.tuxfamily.org
with "unsubscribe" in the subject.
For help email chrony-users-***@chrony.tuxfamily.org
with "help" in the subject.
Trouble? Email ***@chrony.tuxfamily.org.
Ariel Garcia
2018-02-06 13:16:21 UTC
Permalink
Post by Miroslav Lichvar
Post by Miroslav Lichvar
What kernel version is the board running? There was a bug which caused
issues like that and it was fixed few years ago. IIRC it was specific
to 32-bit platforms.
...
Post by Miroslav Lichvar
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?i
d=2619d7e9c92d524cb155ec89fd72875321512e5b
perfect, that was the problem!! Thanks a lot!

I've also tested fully disabling the "tick-less" functionality (forcing the
kernel to emit "ticks" when busy and also when idle) but that did not help.
Said the other way around: having a "tickless" kernel does not seem to be an
obstacle to Chrony :)

The behaviour without the abs64 kernel, on the other hand, is completely
different, with
Residual freq
and Skew
to jump to ridiculously high values once the correct NTP time is reached...

Thanks again for you support!
--
To unsubscribe email chrony-users-***@chrony.tuxfamily.org
with "unsubscribe" in the subject.
For help email chrony-users-***@chrony.tuxfamily.org
with "help" in the subject.
Trouble? Email ***@chrony.tuxfamily.org.
Charles Muggen
2018-02-06 17:20:23 UTC
Permalink
I have a question.
There seem to be two threads running at the same time in this inquiry.
Is there a way to separate the threads?
Sent: Tuesday, February 06, 2018 at 3:25 AM
Subject: Re: [chrony-users] How to avoid oversteering
Post by Ariel Garcia
Hello,
i am trying to get Chrony 3.2 running without stepping the clock, but i
find that it oversteers by a huge amount. I observe that it starts driving
the system clock to the right value, but then moves it more that the
initial offset in the opposite direction, and starts "oscillating".
This looks like a broken system clock. chronyd is telling the kernel
to slow down or speed up the clock, but it doesn't happen.
What kernel version is the board running? There was a bug which caused
issues like that and it was fixed few years ago. IIRC it was specific
to 32-bit platforms.
--
Miroslav Lichvar
--
with "unsubscribe" in the subject.
with "help" in the subject.
--
To unsubscribe email chrony-users-***@chrony.tuxfamily.org
with "unsubscribe" in the subject.
For help email chrony-users-***@chrony.tuxfamily.org
with "help" in the subject.
Trouble? Email ***@chrony.tuxfamily.org.
Loading...