Simpler Navigation for Servers and Operating Systems - Please Update Your Bookmarks
Completed: a much simpler Servers and Operating Systems section of the Community. We combined many of the older boards, so you won't have to click through so many levels to get at the information you need. Check the consolidated boards here as many sub-forums are now single boards.
If you have bookmarked forums or discussion boards in Servers and Operating Systems, we suggest you check and update them as needed.
cancel
Showing results for 
Search instead for 
Did you mean: 

NTP drift file

SOLVED
Go to solution
suki
Frequent Advisor

NTP drift file

Hi,
In my network I have an NTP Server already running one. Now I need to configure a 11.0 machine as a ntp client to synchronise the time from my NTP server. When I go through the threads I came across a file called driftfile other than /etc/ntp.conf and /etc/rc.config.d/netdaemons. Can someone clear me about the NTP config and the drift file.
Thanks,
suki.
6 REPLIES
Clemens van Everdingen
Honored Contributor

Re: NTP drift file

Hi,

See this doc for configuring NTP

http://docs.hp.com/hpux/onlinedocs/B2355-90685/B2355-90685.html

Look in the left column for ntp configuring.

C.
The computer is a great invention, there are as many mistakes as ever, but they are nobody's fault !
Christian Gebhardt
Honored Contributor
Solution

Re: NTP drift file

Hi
look at "man xntpd" for a first overview

A sample ntp.conf:

#
# Stratum 3/4 client setup
#
#
# local clock
server 127.127.1.0
# show poor quality of local clock
fudge 127.127.1.0 stratum 10
# frequency error file
driftfile /etc/ntp.drift
# intern time servers (local stratum 1 net)
server
server
server
# allow time servers full access
restrict
restrict
restrict
# serve/peer time to local net but do not let modify or synchronize to anything
restrict mask 255.255.255.0 notrust nomodify
# ignore everything else
restrict default ignore


man xntpd:
...
driftfile filename

Specifies the name of the file used to record the ``drift'' (or
frequency error) value xntpd has computed. If the file exists on
startup, it is read and the value used to initialize xntpd's internal
value of the frequency error. The file is then updated once every
hour by replacing the old file with a new one containing the current
value of the frequency error. Note that the file is updated by first
writing the current drift value into a temporary file and then using
rename(2) to replace the old version. This implies that xntpd must
have write permission for the directory the drift file is located in,
and that file system links, symbolic or otherwise, should probably be
avoided.
...

Chris
Jerome Baron
Respected Contributor

Re: NTP drift file

Hi,

You can configure your ntp client via sam :
Time->NTP Network Time sources.

Regards,
Jerome
Clemens van Everdingen
Honored Contributor

Re: NTP drift file

Hi,

Here is the small explanation about the driftfile from the above doc.

xntpd computes the error in the frequency of the clock in the local host. It usually takes xntpd a day or so after it is started to compute a good estimate of the frequency error. The current value of the frequency error may be stored in a driftfile. The driftfile allows a restarted xntpd to reinitialize itself to the estimate stored in the driftfile, saving about a day's worth of time in recomputing a good frequency estimate. You specify the path and name of the driftfile.

C.
The computer is a great invention, there are as many mistakes as ever, but they are nobody's fault !
T G Manikandan
Honored Contributor

Re: NTP drift file

If you are to configure ntp client then

//*
1.Make entries of server-name in /etc/ntp.conf

server

2.Run ntpdate
(Make sure xntpd is stopped before issuing the command)
#ntpdate

3.Start xntpd
edit /etc/rc.config.d/netdaemons and set these line as following:
export NTPDATE_SERVER= ip address of the ntp server
export XNTPD=1
/sbin/init.d/xntpd start

4.ntpq -p
to check the synchro. of client with the server.
*//

The drift-file in the ntp.conf file is used to log the
drift value when the NTP daemon was last running.

This file is not reliable.It usually takes some time to have got updated with entries.

you can use
#ntpq -p
from the client to check up the synchronization of client with the server.


suki
Frequent Advisor

Re: NTP drift file

Thanks to everybody who cleared my doubts