当前位置: > Linux发行版 > FreeBSD >

FreeBSD系统时间调整

时间:2014-11-20 11:37来源:linux.it.net.cn 作者:IT

先设置时区:

# tzsetup

再与国家授时中心服务器对时:

# ntpdate 210.72.145.44

以后自动同步:

首先修改 /etc/rc.conf 添加

ntpd_enable="YES"

到最后一行。

然后配置对时服务器:

# vi /etc/ntp.conf

server 210.72.145.44 prefer
server 159.226.154.47
server 127.127.1.0
fudge 127.127.0.1 stratum 5
restrict default ignore
restrict 127.0.0.0 mask 255.0.0.0
restrict 192.168.0.0 mask 255.255.255.0 noquery nopeer notrust
restrict 210.72.145.44 noquery
restrict 159.226.154.47 noquery
driftfile /var/db/ntpd.drift

#/var/run/xntpd.pid



(责任编辑:IT)
------分隔线----------------------------