]> git.ipfire.org Git - thirdparty/chrony.git/commit
sources: add option to limit selection of unreachable sources
authorMiroslav Lichvar <mlichvar@redhat.com>
Tue, 5 Aug 2025 14:08:40 +0000 (16:08 +0200)
committerMiroslav Lichvar <mlichvar@redhat.com>
Thu, 7 Aug 2025 08:18:31 +0000 (10:18 +0200)
commit9b183fe98f99957a870ed17c1602c161c636e6d8
treeee862c32af0b6a3d0a43c25af7803e520c808979
parentbe7f5e8916aea78776c08a23d39cfe042acbec8d
sources: add option to limit selection of unreachable sources

Add maxunreach option to NTP sources and refclocks to specify the
maximum number of polls that the source can stay selected for
synchronization when it is unreachable (i.e. no valid sample was
received in the last 8 polls).

It is an additional requirement to having at least one sample more
recent than the oldest sample of reachable sources.

The default value is 100000. Setting the option to 0 disables selection
of unreachable sources, which matches RFC 5905.
16 files changed:
candm.h
client.c
cmdmon.c
cmdparse.c
conf.c
doc/chrony.conf.adoc
doc/chronyc.adoc
ntp_core.c
refclock.c
refclock.h
sources.c
sources.h
srcparams.h
test/simulation/110-chronyc
test/simulation/150-maxunreach [new file with mode: 0755]
test/unit/sources.c