0

I start chronyd (3.4) with 4 initial servers, 2 remote (from a pool) and 2 local hosts on the same subnet, for example:

initstepslew 1 0.xxx.pool.ntp.org 1.xxx.pool.ntp.org 192.168.63.114 192.168.63.121
makestep 1 3

It may be that the system is not connected to the internet so that synchronizing to other local hosts is acceptable. It is however (also) possible that the other local players rebooted pretty-much simultaneously and so they may also be trying to get their initial time sync at the same time.

Sometimes the result can be that all 4 servers are marked as falsetickers and the startup never completes (does not fork into background), leaving the system time at 01 January 1970.

MS Name/IP address         Stratum Poll Reach LastRx Last sample               
===============================================================================
^x 199.182.221.110               2   6     0   18h  -18717d[-18717d] +/-   60ms
^x 206.75.147.25                 2   6     0   18h  -18717d[-18717d] +/-   66ms
^x 192.168.63.114                4   6     0   18h  -18717d[-18717d] +/- 1115us
^x 192.168.63.121                4   6     0   18h  -18717d[-18717d] +/- 2394us

Any idea what is going on here and anything I can do to avoid and/or correct the situation?

awy
  • 61
  • 4

1 Answers1

1

In short, I believe this is because you have two pairs of time servers at the same Stratum. If the two servers at the same Stratum differ in the time they report, chronyd will not be able to determine which one of them is the correct time source.

To get around this, you could add more time sources/servers to give chronyd a better chance of figuring out the "correct" time.

Alternatively, you could tell chronyd to "trust" one server from each of the pairs. This will allow it to simply 'assume' one of the servers is reporting the correct time and it will sync without defining them as false tickers. i.e. in your configuration definition you would do:

server 199.182.221.110 trust
server 206.75.147.25
server 192.168.63.114 trust
server 192.168.63.121

See answer and references here:

Both my ntp servers are marked as falsetickers in the status

Can ntpd/chronyd be used with two NTP servers, specifying one as primary and another as backup?

loris
  • 11
  • 1
  • It "feels" wrong to define one of the local servers as trusted in this case. Since the problem only occurs for the initial sync a solution is to use only one. I am not yet convinced that even that works in all cases. – awy Sep 17 '21 at 15:49