ntp服務搭建與配置

2021-09-11 20:54:50 字數 843 閱讀 7754

ntp服務搭建與配置

服務端

1.yum install -y ntp

2.mv /etc/ntp.conf /etc/ntp.conf.bak

3.vi /etc/ntp.conf

server 127.127.1.0

fudge 127.127.1.0 stratum 11

4.service ntpd restart

5.systemctl enable ntpd.service

檢查

客戶端

1.yum install -y ntp

2.mv /etc/ntp.conf /etc/ntp.conf.bak

3.vi /etc/ntp.conf

server 127.127.1.0

fudge 127.127.1.0 stratum 11

4.service ntpd restart

5.systemctl enable ntpd.service

檢查

6.執行ntpdata -u 服務端ip

7.看到以上資訊後說明ntp同步成功

NTP服務搭建

root bogon yum y install ntp ntpdate.x86 64server 0.centos.pool.ntp.org iburst server 1.centos.pool.ntp.org iburst server 2.centos.pool.ntp.org iburst...

NTP服務搭建

restrict 192.168.2.0 mask 255.255.255.0 nomodify 允許192.168.2.0段的機器同步時間,nomodify 表明客戶端不可以修改伺服器的位址 server 202.120.2.101 上海交大 server s2m.time.edu.cn 北京大學...

配置ntp服務

客戶端 一 在 etc crontab 2 etc ntp.sh 每兩個小時校對一次時間 二 在 etc ntp.sh中新增 bin bash ntpdate 172.19.61.110 改變 etc ntp.sh的許可權 chmod 700 etc ntp.sh 三 etc init.d fcro...