TIME_ERROR: 0x41: Clock Unsynchronized

Hello,
Replaced 2 NTP clients with new clients . But when the new virtual appliance comes up they are not able to sync with the NTP server and are stuck at .INIT.

remote refid st t when poll reach delay offset jitter

10.41.2.123 .INIT. 16 u - 256 0 0.000 +0.000 0.000
10.132.30.50 .INIT. 16 u - 256 0 0.000 +0.000 0.000
10.80.15.64 .INIT. 16 u - 256 0 0.000 +0.000 0.000
10.225.3.7 .INIT. 16 u - 256 0 0.000 +0.000 0.000

However ntpdate -q to the above servers shows startum 1 and less offset.

ping to the server also works fine and there is no firewall rules also.

ash-4.0# ntpq -c rv

1associd=0 status=0615 leap_none, sync_ntp, 1 event, clock_sync, 2version="ntpd 4.2.8p15@1.3728-o Thu Jul 29 19:56:51 UTC 2021 (1)", 3processor="x86_64", system="Linux/4.9.58", leap=00, stratum=3, 4precision=-24, rootdelay=1.419, rootdisp=7.872, refid=169.254.0.1, 5reftime=e70c0471.3aa81854 Tue, Nov 1 2022 15:47:45.229, 6clock=e70c04a7.1c419589 Tue, Nov 1 2022 15:48:39.110, peer=31571, tc=6, 7mintc=3, offset=-0.130382, frequency=+14.344, sys_jitter=0.000000, 8clk_jitter=0.036, clk_wander=0.001

I read about changing kernel timercounters:

what can i check in my client which has fedora running ?

There are other virtual appliance connected to same NTP server and are able to sync.

@aaa2022, welcome to the community!

What does the command
grep ntpd /var/log/messages
give?

Hello,
This is what is see in log… ntpd exiting continuosly…

95 2022-11-02T00:46:18-05:00 daemon host.com ntpd[7058]: notice ntpd 4.2.8p15@1.3728-o Thu     Jul 29 19:56:51 UTC 2021 (1): Starting
 96 2022-11-02T00:46:18-05:00 daemon host.com ntpd[7058]: notice Command line: /usr/bin/ntp    d -x -a -c /tmpfs/ntp.conf -f /storage/etc/ntp.drift
 97 2022-11-02T00:46:18-05:00 daemon host.com ntpdm ntpd[7058]: notice --------------------------    --------------------------
 98 2022-11-02T00:46:18-05:00 daemon host.com ntpd ntpd[7058]: notice ntp-4 is maintained by Net    work Time Foundation,
 99 2022-11-02T00:46:18-05:00 daemon host.com ntpd ntpd[7058]: notice Inc. (NTF), a non-profit 5    01(c)(3) public-benefit
100 2022-11-02T00:46:18-05:00 daemon host.com ntpdm ntpd[7058]: notice corporation.  Support and     training for ntp-4 are
101 2022-11-02T00:46:18-05:00 daemon host.com ntpd ntpd[7058]: notice available at https://www.n    wtime.org/support
102 2022-11-02T00:46:18-05:00 daemon host.com ntpd ntpd[7058]: notice --------------------------    --------------------------
103 2022-11-02T00:46:18-05:00 daemon host.com ntpd ntpd[7060]: info proto: precision = 0.055 use    c (-24)
104 2022-11-02T00:46:18-05:00 daemon host.com ntpdm ntpd[7060]: info basedate set to 2021-07-17
105 2022-11-02T00:46:18-05:00 daemon host.com ntpd ntpd[7060]: info gps base set to 2021-07-18 (    week 2167)
106 2022-11-02T00:46:18-05:00 daemon host.com ntpdm ntpd[7060]: info Listen and drop on 0 v6wildc    ard [::]:123
107 2022-11-02T00:46:18-05:00 daemon host.com ntpd ntpd[7060]: info Listen and drop on 1 v4wildc    ard 0.0.0.0:123
108 2022-11-02T00:46:18-05:00 daemon host.com ntpd ntpd[7060]: info Listen normally on 2 lo 127.    0.0.1:123
109 2022-11-02T00:46:18-05:00 daemon host.com ntpd ntpd[7060]: info Listen normally on 3 eth1 10    .80.39.34:123
110 2022-11-02T00:46:18-05:00 daemon host.com ntpd ntpd[7060]: info Listen normally on 4 tun2 16    9.254.0.9:123
111 2022-11-02T00:46:18-05:00 daemon host.com ntpd ntpd[7060]: info Listen normally on 5 lo [::1    ]:123

112 2022-11-02T00:46:18-05:00 daemon host.com ntpd ntpd[7060]: info Listening on routing socket     on fd #22 for interface updates
113 2022-11-02T00:46:18-05:00 daemon host.com ntpd ntpd[7060]: info kernel reports TIME_ERROR: 0    x41: Clock Unsynchronized
114 2022-11-02T00:46:18-05:00 daemon host.com ntpd [7060]: info kernel reports TIME_ERROR: 0    x41: Clock Unsynchronized

115 2022-11-02T00:48:31-05:00 daemon host.com ntpd ntpdate[8833]: notice step time server 10.41.    2.123 offset +0.555532 sec
116 2022-11-02T00:50:03-05:00 daemon host.com ntpd ntpdate[10020]: notice step time server 10.41    .2.123 offset +0.003425 sec
117 2022-11-02T00:50:26-05:00 daemon host.com ntpd ntpdate[10367]: notice step time server 10.13    2.30.50 offset +0.000795 sec
118 2022-11-02T00:50:49-05:00 daemon host.com ntpd ntpdate[10624]: notice step time server 10.80    .15.64 offset +0.000838 sec
119 2022-11-02T00:51:14-05:00 daemon host.com ntpd ntpdate[10923]: notice step time server 10.22    5.3.7 offset +0.001479 sec
120 2022-11-02T00:54:17-05:00 daemon host.com ntpd ntpd[7060]: err Invalid-NAK error at 478 10.8    0.39.34<-172.16.109.165
121 2022-11-02T01:02:22-05:00 daemon host.com ntpd ntpd[7060]: err Invalid-NAK error at 964 10.8    0.39.34<-172.16.109.168
122 2022-11-02T01:03:44-05:00 daemon host.com ntpd ntpd[7060]: notice ntpd exiting on signal 15     (Terminated)
123 2022-11-02T01:03:44-05:00 daemon host.com ntpd ntpd[7060]: info 10.41.2.123 local addr 10.80    .39.34 -> <null>
124 2022-11-02T01:03:44-05:00 daemon host.com ntpd ntpd[7060]: info 10.132.30.50 local addr 10.8    0.39.34 -> <null>
125 2022-11-02T01:03:44-05:00 daemon host.com ntpdm ntpd[7060]: info 10.80.15.64 local addr 10.80    .39.34 -> <null>
126 2022-11-02T01:03:44-05:00 daemon host.com ntpd ntpd[7060]: info 10.225.3.7 local addr 10.80.    39.34 -> <null>
127 2022-11-02T01:03:44-05:00 daemon host.com ntpd ntpd[7060]: info 127.127.1.1 local addr 127.0    .0.1 -> <null>
128 2022-11-02T01:03:44-05:00 daemon host.com ntpd ntpdate[20922]: notice ntpdate 4.2.8p15@1.372    8-o Thu Jul 29 19:56:51 UTC 2021 (1)
130 2022-11-02T01:03:51-05:00 daemon host.com ntpd ntpd[21050]: notice ntpd 4.2.8p15@1.3728-o Th    u Jul 29 19:56:51 UTC 2021 (1): Starting
131 2022-11-02T01:03:51-05:00 daemon host.com ntpd ntpd[21050]: notice Command line: /usr/bin/nt    pd -x -a -c /tmpfs/ntp.conf -f /storage/etc/ntp.drift

Is " ```
err Invalid-NAK error at

what authentication parameters we need to check?

Is the ntpd crashing because of TIME_ERROR or Invalid-NAK?
what parameters can we check?

Probably because of authentication failure. You shall first make sure your ntpd instance can be operating normally without authentication, then add the authentication key afterwards.

thanks .tried by removing the authentication but still see the issue.
ntp is still stuck at .INIT.
And i see the “TIME_ERROR”

405631:2022-11-23T00:04:09-06:00 daemon host.com ntpd[31591]: notice ntpd exiting on signal 15 (Terminated)
405632:2022-11-23T00:04:09-06:00 daemon host.com ntpd[31591]: info 10.41.2.123 local addr 10.162.37.100 -> <null>
405633:2022-11-23T00:04:09-06:00 daemon host.com ntpd[31591]: info 10.132.30.50 local addr 10.162.37.100 -> <null>
405634:2022-11-23T00:04:09-06:00 daemon host.com ntpd[31591]: info 10.80.15.64 local addr 10.162.37.100 -> <null>
405635:2022-11-23T00:04:09-06:00 daemon host.com ntpd[31591]: info 10.225.3.7 local addr 10.162.37.100 -> <null>
405636:2022-11-23T00:04:09-06:00 daemon host.com ntpd[31591]: info 169.254.0.1 local addr 169.254.0.12 -> <null>
405637:2022-11-23T00:04:09-06:00 daemon host.com ntpd[31591]: info 127.127.1.1 local addr 127.0.0.1 -> <null>
405638:2022-11-23T00:04:09-06:00 daemon host.com ntpdate[31430]: notice ntpdate 4.2.8p15@1.3728-o Thu Jul 29 19:56:51 UTC 2021 (1)
405647:2022-11-23T00:04:16-06:00 daemon host.com ntpdate[31430]: notice adjust time server 10.80.15.64 offset +0.000136 sec
405648:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31556]: notice ntpd 4.2.8p15@1.3728-o Thu Jul 29 19:56:51 UTC 2021 (1): Starting
405649:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31556]: notice Command line: /usr/bin/ntpd -x -a -c /tmpfs/ntp.conf -f /storage/etc/ntp.drift
405650:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31556]: notice ----------------------------------------------------
405651:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31556]: notice ntp-4 is maintained by Network Time Foundation,
405652:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31556]: notice Inc. (NTF), a non-profit 501(c)(3) public-benefit
405653:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31556]: notice corporation.  Support and training for ntp-4 are
405654:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31556]: notice available at https://www.nwtime.org/support
405655:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31556]: notice ----------------------------------------------------
405656:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31558]: info proto: precision = 0.056 usec (-24)
405657:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31558]: info basedate set to 2021-07-17
405658:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31558]: info gps base set to 2021-07-18 (week 2167)
405659:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31558]: info Listen and drop on 0 v6wildcard [::]:123
405660:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31558]: info Listen and drop on 1 v4wildcard 0.0.0.0:123
405661:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31558]: info Listen normally on 2 lo 127.0.0.1:123
405662:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31558]: info Listen normally on 3 eth1 10.162.37.100:123
405663:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31558]: info Listen normally on 4 tun2 169.254.0.12:123
405664:2022-11-23T00:04:16-06:00 daemon host.comntpd[31558]: info Listen normally on 5 lo [::1]:123
405665:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31558]: info Listening on routing socket on fd #22 for interface updates
405666:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31558]: info kernel reports TIME_ERROR: 0x4041: Clock Unsynchronized
405667:2022-11-23T00:04:16-06:00 daemon host.com ntpd[31558]: info kernel reports TIME_ERROR: 0x4041: Clock Unsynchronized
436041:2022-11-23T00:06:21-06:00 daemon host.com ntpd[31558]: notice ntpd exiting on signal 15 (Terminated)
436042:2022-11-23T00:06:21-06:00 daemon host.com ntpd[31558]: info 10.41.2.123 local addr 10.162.37.100 -> <null>
436043:2022-11-23T00:06:21-06:00 daemon host.com ntpd[31558]: info 10.132.30.50 local addr 10.162.37.100 -> <null>
436044:2022-11-23T00:06:21-06:00 daemon host.com ntpd[31558]: info 10.80.15.64 local addr 10.162.37.100 -> <null>
436045:2022-11-23T00:06:21-06:00 daemon host.com ntpd[31558]: info 10.225.3.7 local addr 10.162.37.100 -> <null>
436046:2022-11-23T00:06:21-06:00 daemon host.com ntpd[31558]: info 169.254.0.1 local addr 169.254.0.12 -> <null>
436047:2022-11-23T00:06:21-06:00 daemon host.com ntpd[31558]: info 127.127.1.1 local addr 127.0.0.1 -> <null>
436048:2022-11-23T00:06:21-06:00 daemon host.com ntpdate[959]: notice ntpdate 4.2.8p15@1.3728-o Thu Jul 29 19:56:51 UTC 2021 (1)
440645:2022-11-23T00:06:28-06:00 daemon host.com ntpdate[959]: notice adjust time server 10.80.15.64 offset +0.000173 sec
440646:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1027]: notice ntpd 4.2.8p15@1.3728-o Thu Jul 29 19:56:51 UTC 2021 (1): Starting
440647:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1027]: notice Command line: /usr/bin/ntpd -x -a -c /tmpfs/ntp.conf -f /storage/etc/ntp.drift
440648:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1027]: notice ----------------------------------------------------
440649:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1027]: notice ntp-4 is maintained by Network Time Foundation,
440650:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1027]: notice Inc. (NTF), a non-profit 501(c)(3) public-benefit
440651:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1027]: notice corporation.  Support and training for ntp-4 are
440652:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1027]: notice available at https://www.nwtime.org/support
440653:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1027]: notice ----------------------------------------------------
440686:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1029]: info proto: precision = 0.055 usec (-24)
440687:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1029]: info basedate set to 2021-07-17
440688:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1029]: info gps base set to 2021-07-18 (week 2167)
440689:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1029]: info Listen and drop on 0 v6wildcard [::]:123
440690:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1029]: info Listen and drop on 1 v4wildcard 0.0.0.0:123
440691:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1029]: info Listen normally on 2 lo 127.0.0.1:123
440692:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1029]: info Listen normally on 3 eth1 10.162.37.100:123
440693:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1029]: info Listen normally on 4 tun2 169.254.0.12:123
440694:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1029]: info Listen normally on 5 lo [::1]:123
440695:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1029]: info Listening on routing socket on fd #22 for interface updates
440696:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1029]: info kernel reports TIME_ERROR: 0x41: Clock Unsynchronized
440697:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1029]: info kernel reports TIME_ERROR: 0x41: Clock Unsynchronized
462736:2022-11-23T00:08:26-06:00 daemon host.com ntpd[1029]: notice ntpd exiting on signal 15 (Terminated)

looks like ntpd is exiting because of below error only… and this happens continously…
Ay pointers what details can i check?

kernel reports TIME_ERROR: 0x41: Clock Unsynchronized
440697:2022-11-23T00:06:28-06:00 daemon host.com ntpd[1029]: info kernel reports TIME_ERROR: 0x41: Clock Unsynchronized

No, the kernel reports TIME_ERROR: 0x41: Clock Unsynchronized line is normal in ntpd startup. The real problem is the following:

notice ntpd exiting on signal 15 (Terminated)

which means something (maybe the init script or systemd etc.) killed ntpd by signaling it. You may debug by start ntpd manually with something like:

 /usr/sbin/ntpd -g -p /var/run/ntpd.pid

Hope this helps.

2 Likes

thanks a lot… started ntpd again and used ntpdate -B .
Triggered service restart and now able to sync to NTP server.

2 Likes