Linux - Chrony时间同步

# step 1 - install packages
[09:50:34 root@centos8 ~]#yum -y install chrony

# step 2 - edit chrony.conf 
[09:50:51 root@centos8 ~]#rpm -ql chrony
/etc/NetworkManager/dispatcher.d/20-chrony
/etc/chrony.conf
/etc/chrony.keys
/etc/dhcp/dhclient.d/chrony.sh

# step 3 - set the time server and allow
[09:56:13 root@centos8 data]#cat /etc/chrony.conf 
# Use public servers from the pool.ntp.org project.
# Please consider joining the pool (http://www.pool.ntp.org/join.html).
server ntp.aliyun.com iburst
server ntp1.aliyun.com iburst
server ntp2.aliyun.com iburst

# Allow NTP client access from local network.
allow 10.0.0.0/24

# step 4 - install bind at client and edit configure file
add server as the main server
[09:59:17 root@centos8 data]#cat /etc/chrony.conf 
# Use public servers from the pool.ntp.org project.
# Please consider joining the pool (http://www.pool.ntp.org/join.html).
server 10.0.0.3 iburst

 

posted @ 2021-06-06 10:00  每天都在学习的自己  阅读(159)  评论(0)    收藏  举报