linux 自动更新时间

黎东
L、先森
2018-02-27 0 1874

安装ntp服务

yum -y install ntp

开启ntp服务

service ntpd start

service ntpd status          #查看ntpd服务状态
service ntpd start           #启动ntpd服务
service ntpd stop            #停止ntpd服务
service ntpd restart         #重启ntpd服务

检查ntp服务是否开机启动,将其设置为开机启动

 chkconfig --list ntpd
 
 chkconfig ntpd on


linux