2010/01/15

NTP (network time protocol) configuration

NTP clinet 設定:
Solaris: /etc/inet/ntp.conf
Linux: /etc/ntp.conf
server  192.168.1.1
server  time.windows.com
以上設定讓自己與192.168.1.1 and time.windows.com作時間同步。

立即手動同步,下指令:

[root@rhel]# ntpdate 192.168.1.1
15 Jan 22:41:24 ntpdate[4042]: adjust time server 207.46.197.32 offset 0.387979 sec

設定一部 NTP server,ntp.conf 內容

server          127.127.1.0     # local clock
fudge           127.127.1.0 stratum 10
driftfile       /var/lib/ntp/drift
broadcastdelay  0.008
keys            /etc/ntp/keys

#server: Specifies that a server is running on the host (own local clock)
#fudge: Passes additional information to the clock driver
#stratum 10: Manually sets the Stratum the server should operate at (1-15)
#driftfile: Specifies the location of the frequency file
#broadcastdelay: Sets the propagation delay from the server when broadcasting
#keys: Store a list of keys needed for any cryptographic links

NTP daemon要啟動(Linux)

service ntpd stop
service ntpd start

沒有留言:

張貼留言