On Tue, Mar 16, 2021 at 03:41:01AM +, Ryan Govostes wrote:
> As a fallback for alternatives like chrony, it does some trick where it
> creates a timer which the kernel cancels when the clock is synchronized. But
> the documentation cautions that this is not necessarily reliable.
>
> https://github.com/systemd/systemd/pull/8494/files
>
> Does this work well with chrony? Or is there a better way to set up
> time-sync.target?
I doubt it works well with chrony. One issue is that chronyd may not
step the clock if the initial offset is too small. You would need to
specify a zero threshold for makestep. A bigger issue is that the
clock status is set separately, after setting the clock, so there is a
race between chronyd setting the clock status and waitsync checking
it. time-wait would need to check the status periodically.
Use the chronyc waitsync command instead. There is an example
chrony-wait service in the examples directory in the chrony sources
using that command. It's packaged in some distros.
--
Miroslav Lichvar
--
To unsubscribe email chrony-users-requ...@chrony.tuxfamily.org
with "unsubscribe" in the subject.
For help email chrony-users-requ...@chrony.tuxfamily.org
with "help" in the subject.
Trouble? Email listmas...@chrony.tuxfamily.org.