NTP服务器配置

vi /etc/ntp.conf

server 120.119.28.1
server 220.135.58.124

server 129.6.15.28
server 129.6.15.29
# Use Ubuntu's ntp server as a fallback.
#server ntp.ubuntu.com
server 91.189.94.4
#server 91.189.89.199

vi /etc/network/iptables.up.rules

-A INPUT -s 129.6.15.0/24 -j ACCEPT -m comment --comment "time.nist.gov"
-A INPUT -s 91.189.94.4 -j ACCEPT -m comment --comment "NTP-ubuntu"
-A INPUT -s 91.189.89.199 -j ACCEPT -m comment --comment "NTP-ubuntu"
-A INPUT -s 202.112.0.0/16 -j ACCEPT -m comment --comment "cn.pool.ntp.org"
-A INPUT -s 120.119.28.1 -j ACCEPT -m comment --comment "tw.pool.ntp.org"
-A INPUT -s 220.135.58.124 -j ACCEPT -m comment --comment "tw.pool.ntp.org"

-A OUTPUT -d 91.189.94.4 -j ACCEPT -m comment --comment "NTP"
-A OUTPUT -d 91.189.89.199 -j ACCEPT -m comment --comment "NTP"
-A OUTPUT -s 202.112.0.0/16 -j ACCEPT -m comment --comment "cn.pool.ntp.org"
-A OUTPUT -s 120.119.28.1 -j ACCEPT -m comment --comment "tw.pool.ntp.org"
-A OUTPUT -s 220.135.58.124 -j ACCEPT -m comment --comment "tw.pool.ntp.org"

飞儿传媒www.firadio.com
原文地址:https://www.cnblogs.com/firadio/p/3912113.html