mirror of
https://github.com/kata-containers/kata-containers.git
synced 2025-06-30 17:22:33 +00:00
rootfs: configure chronyc service with makestep
The current chrony service does not step the system clock, so add the modification to do this if the adjustment is larger than one second Fixes: #316 Signed-off-by: Yang, Wei <wei.yang1@linux.alibaba.com>
This commit is contained in:
parent
d9782606bb
commit
add0d445e8
@ -395,7 +395,12 @@ if [ ${distro} == ubuntu ] || [ ${distro} == debian ] ; then
|
||||
fi
|
||||
|
||||
info "Configure chrony file ${chrony_conf_file}"
|
||||
echo "refclock PHC /dev/ptp0 poll 3 dpoll -2 offset 0" >> ${chrony_conf_file}
|
||||
cat >> "${chrony_conf_file}" <<EOT
|
||||
refclock PHC /dev/ptp0 poll 3 dpoll -2 offset 0
|
||||
# Step the system clock instead of slewing it if the adjustment is larger than
|
||||
# one second, at any time
|
||||
makestep 1 -1
|
||||
EOT
|
||||
|
||||
# Comment out ntp sources for chrony to be extra careful
|
||||
# Reference: https://chrony.tuxfamily.org/doc/3.4/chrony.conf.html
|
||||
|
Loading…
Reference in New Issue
Block a user