1833846 Members
1999 Online
110063 Solutions
New Discussion

Re: Correct time setup

 
SOLVED
Go to solution
Chris Fadrowski
Super Advisor

Correct time setup

I would like to sync my clock (time) with an Win2K server on my domain on a consistent basis. Can someone detail how this procedure is done. It seems that our HPUX servers get off mark quite a bit and it is causing some issues with backup and backup times.
13 REPLIES 13
Helen French
Honored Contributor

Re: Correct time setup

Hi,

What about using NTP ?

# man xntpd

HTH,
Shiju
Life is a promise, fulfill it!
Jeff Schussele
Honored Contributor

Re: Correct time setup

Hi Chris,

You need to use the NTP (Network Time Protocol) daemon - xntpd
The config file for it is /etc/ntp.conf which is where you will set the host to be polled or listened to for time sync. You'll have to set the NT system to be a NTP server.
It is better, however to use a more "accurate" source, such as a GSP radio signal or recognized NTP servers out on the Internet. They would be MUCH more accurate & then you could set the rest of the servers to sync of the internal server being served by the outside server.

Rgds,
Jeff
PERSEVERANCE -- Remember, whatever does not kill you only makes you stronger!
Ceesjan van Hattum
Esteemed Contributor
Solution

Re: Correct time setup

Put in your /etc/ntp.conf

driftfile /etc/ntp.drift
statsdir /tmp/ntpstats

server version 3 prefer
server version 3

That is all..

Link the /etc/rc2.d/S660xntpd to /sbin/init.d/xntpd

You can also set it using 'sam'.
Look at /etc/ntp.drift to check if it works: 'cat' and 'll'.

Success,
Ceesjan

S.K. Chan
Honored Contributor

Re: Correct time setup

I do not know if HP-UX machine can sync it's time with and Win2K server but as far as setting up and NTP client on your Unix box, it's relatively simple..

# vi /etc/rc.config.d/netdameons
..
export NTPDATE_SERVER="servername.domain.com"
export XNTPD=1
..
# vi /etc/ntp.conf
server servername.domain.com
driftfile /etc/ntp.drift
# touch /etc/ntp.drift
# /usr/sbin/xntpd
==> start ntp

# /usr/sbin/ntpq -p
==> check association..
Chris Fadrowski
Super Advisor

Re: Correct time setup

i did this and i am still getting "no association ID's returned" any ideas?
Jeff Schussele
Honored Contributor

Re: Correct time setup

Hi Chris,

You need to install NTP SW & configure the WIN2K system to be an NTP server.
SW & further info can be obtained at:

http://www.eecis.udel.edu/~ntp/software/win9x.html

HTH,
Jeff
PERSEVERANCE -- Remember, whatever does not kill you only makes you stronger!
S.K. Chan
Honored Contributor

Re: Correct time setup

Possible reasons for that ..
1) NTP server cannot be reached over network.
2) NTP server is not running NTP.
3) NTP server's own timeclock is not sync'd up.

James R. Ferguson
Acclaimed Contributor

Re: Correct time setup

Hi Chris:

"No association" means that a suitable time source cannot be found. This could be due to a difference in time between you and your source that exceeds 1000 seconds. Other possibliities include an unreachable source or a server that does not offer NTP packets.

Regards!

...JRF...
Jeff Schussele
Honored Contributor

Re: Correct time setup

Chris,

One final point to consider is the traffic between an NTP server & it's clients.
NTP uses port 123 UDP.
So if a firewall exists in your network between server/client OR you will obtain NTP traffic from outside your network, you'll have to make sure that traffic can pass between the NTP server & it's clients.

Rgds,
Jeff
PERSEVERANCE -- Remember, whatever does not kill you only makes you stronger!
Darrell Allen
Honored Contributor

Re: Correct time setup

Hi Chris,

I use NetTime on several W2K Pro, NT4.0 server, NT4.0 workstation, and Win98 boxes. It's available from:
http://nettime.sourceforge.net

You can install it as a service (if you desire), sync to Internet sources (provided your firewalls allow that), and allow other systems to sync to your system.

I use NTP on my HPUX servers to sync to an internal NTP server but I have tested syncing to a NetTime PC without problem.

Darrell
"What, Me Worry?" - Alfred E. Neuman (Mad Magazine)
MANOJ SRIVASTAVA
Honored Contributor

Re: Correct time setup

Chris

It looks it is not able to reach the server you ahve set for reading the time .

Can you ping to the server with the IP Adress setup in the /etc/ntp.conf file , ofcourse the NTP daemon should eb running.

Here is the link to docs.hp for more trouble shooting :
http://docs.hp.com/cgi-bin/fsearch/framedisplay?top=/hpux/onlinedocs/B2355-90685/B2355-90685_top.html&con=/hpux/onlinedocs/B2355-90685/00/00/63-con.html&toc=/hpux/onlinedocs/B2355-90685/00/00/63-toc.html&searchterms=NTP&queryid=20020415-123421


Manoj Srivastava
Chris Fadrowski
Super Advisor

Re: Correct time setup

thanks to all who helped. I found that the time service on the W2K box was stopped. Once i started this and stopped and started NTP service on teh UNIX box, i got a response. Thanks again.