Set up ntp time server and ntp Time Server
Chapter 1 Introduction to ntp1.1 ntp
NTP(Network Time Protocol) is a Protocol used to synchronize Time between computers in the Network. Its purpose is to synchronize the computer clock to the Coordinated Universal Time UTC, and its accuracy can reach 0.1 ms in the LAN. In most places on the Internet, its accuracy can reach 1-50 ms.
1.2 ntp server deployment
1.2.1 Environment Description System: CentOS 7.4 (CentOS6 comes with CentOS7 to be installed) IP Address: Internet-10.0.0.62 intranet-172.16.1.621.2.2 install ntp yum-y install ntp1.2.3 modify the configuration file vim/etc/ntp. conf # Add restrict 172.16.1.0 mask limit 255.0 nomodify notrap server ntp1.aliyun. com1.2.4 start systemctl start ntpd # start systemctl status ntpd # view status [root @ m02 ~] # Ntpstat # Check whether synchronised is normal (synchronous) to NTP server (5.79.108.34) at stratum 3 time correct to within 1230 MS polling server every 64 s
1.1 client usage
1.3.1 test ntpdate 172.16.1.62 ntpdate-d 172.16.1.621.3.2 Add the scheduled task echo "*/5 *****/usr/sbin/ntpdate 172.16.1.62 &>/dev/null">/var/spool /cron/root