Chrony Clients to the GPS Clocks

apt-get install chrony

systemctl enable chrony
systemctl start chrony
systemctl status chrony

/etc/chrony/chrony.conf
# Source servers
server gps1.my.side iburst
server gps2.my.side iburst
pool pool.ntp.org maxsources 3

# Act as an NTP server
#allow

# Only allow chronyc from the localhost
cmdallow 127.0.0.1

# Record the rate at which the system clock gains/losses time.
driftfile /var/lib/chrony/drift

# Allow the system clock to be stepped in the first three updates
# if its offset is larger than 1 second.
makestep 1.0 3

# Notify on error correction > 0.5 seconds
logchange 0.5

# Enable kernel synchronization of the real-time clock (RTC).
rtcsync

# Lock clock in to RAM
lock_all

# RTS
sched_priority 1

# Fudge Stratum if we cannot reach the internet
local stratum 10

# Save on exit
dumponexit
dumpdir /var/log/chrony

# Require 2 time sources before adjusting clock
minsources 2

# Get TAI-UTC offset and leap seconds from the system tz database.
leapsectz right/UTC
leapsecmode slew
maxslewrate 1000
smoothtime 400 0.001 leaponly

# Specify directory for log files.
logdir /var/log/chrony

# Select which information is logged.
log measurements statistics tracking

systemctl restart chrony

netstat -ant

watch “chronyc sources -v”

Hits: 10

Leave a Reply