首页 > 其他 > 详细

CentOS7下部署NTP服务

时间:2019-05-16 15:52:48      阅读:102      评论:0      收藏:0      [点我收藏+]

1、NTP服务器环境介绍

操作系统:CentOS Linux release 7.2.1511 (Core) 

内核:3.10.0-327.4.5.el7.x86_64

主机名:ntp01

2、安装ntp服务

yum -y install ntp

3、修改 ntp配置

(1)driftfile /var/lib/ntp/drift

记录和上级时间服务器的时间差异,默认配置,保留

(2)restrict default nomodify

表示nomodify客户端可以同步时间

(3)restrict 127.0.0.1

         restrict ::1

允许本机的一切操作,默认策略,保留

(4)restrict ntp.aliyun.com

 阿里云NTP服务可修改本NTP服务时间

(5)server ntp.aliyun.com

 添加阿里云时间源

4、启动NTP服务

启动:systemctl start ntpd

设置开机自启:systemctl enable ntpd

确认事件源:ntpq -p

CentOS7下部署NTP服务

原文:https://www.cnblogs.com/xuefeier/p/10875809.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!