Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problem starting xntpd on AIX 4.3 4

Status
Not open for further replies.

tlemons

MIS
Jun 27, 2002
58
US
Hi

I want to run NTP on our AIX 4.3 system, but see this when I start it:

[ ~ ]: startsrc -s xntpd
0513-059 The xntpd Subsystem has been started. Subsystem PID is 22980.
[ ~ ]: ps -ef | grep 22980
root 24796 21408 2 18:38:07 pts/4 0:00 grep 22980
[ ~ ]:

Two questions, if I may:

1) I searched through the AIX 4.3 documentation for an hour, and didn't find a section on setting up NTP. Has anyone find such a section (or a whitepaper or anything)?

2) Where would startsrc or xntpd write error messages? I don't know where to go to look for information on why the process started and, apparently, immediately exited/died.

Many thanks!
tl
 
Have you set up the ntp.conf file correctly? I have a set of procedures I used to set this up and can post them probably tomorrow. I also explained this in another thread and if I can find that, I'll let you know what it is.
 
I couldn't find the thread where I have answered this before, so here are the instructions I have used to set this up on my systems. These instructions assume you are getting your time from a source on the internet. You can do an internet search on xntp or ntp to find systems that allow themselves to be used this way.

These instructions also say that the broadcast time server to the other systems in my environment is an HP system. The set up is the same on an AIX system for the broadcast time server, except for where the driftfile goes (for some reason -- it really doesn't matter where you put the driftfile or trace file, I guess).

If you are only setting up one system to get the proper time from an outside source, use the instructions for "mercury's" set up near the end of this reply.

Let me know if this helps and works for you.

All Unix systems have been set up to run the xntp time daemon. The AIX system is set up as a client to receive broadcasts of the correct time from mercury. Mercury has been set up to obtain the correct time from time.domainname.edu, a server at <some institution>.

The xntpd daemon is automatically started at system boot by /etc/inittab (xntp:2:eek:nce:/usr/bin/startsrc –s xntp > /dev/console 2>&1). The daemon is stopped when the system boots by the following line in the /etc/rc.shutdown file: /usr/bin/stopsrc –s xntpd > /dev/console 2>&1.

Following are the contents of the system’s /etc/ntp.conf file, which specifies parameters for the xntpd daemon on the client. The procedure for setting up NTP was devised from the ntp.conf file on mercury.

broadcastclient yes [specifies that the system waits to receive correct time broadcast by another server]
driftfile /etc/ntp.drift [specifies the name and location of the driftfile for the system]
server mercury.mycompany.com [specifies which server is expected to broadcast the time]

Following are the contents of mercury’s /etc/ntp.conf file, which specifies the parameters for this broadcast server:

server time.domainname.edu version 3 prefer
fudge 127.127.1.0 stratum 1
logfile /etc/ntp.log
driftfile /var/adm/ntp.drift
broadcast 224.0.1.1 version 3
broadcastclient no

Once the configuration file is set up on both the client and the server, test that ntp is running by using the following procedure:
1. At the command line, type ntpq.
2. At the ntpq> prompt, type peer.
You should receive information as follows:
mercury.mycompany.com renaissance.Ser 3 u 44 64 377 0.40 0.179 0.03.
3. Type quit to get back to the Unix command prompt.
 
Hi bi

Thanks for the reply. I learned several things that I needed to know from it (specifically, how to enable ntp startup and shutdown). I did triple-check my ntp.conf file, and it seems to be appropriate. But, startsrc -s xntpd still creates a process that fails immediately and silently. Does startsrc or xntpd log an error anywhere?

Many thanks!
tl
 
tlemons,

Thanks. I'm not sure why xntpd won't stay up. Have you checked your syslog for any errors? Do you have ntp listed in your /etc/services file? I'm wondering if you have all of the necessary filesets installed -- but I'm not sure which filesets are required.

There is a long paper about xntp at Again, it is something that looks more specific to HP, but xntp is a pretty standard protocol. It might help. Check that out and I'll look around for some more troubleshooting hints for you.
 
Hi

/etc/services looks good:

[ ~ ]: cat /etc/services | grep ntp
nntp 119/tcp readnews untp # USENET News Transfer Protocol
ntp 123/tcp # Network Time Protocol
ntp 123/udp # Network Time Protocol
[ ~ ]:

Which log file should I be looking at, and using which tool to view it:
[ ~ ]: ls -l /var/adm/ras
total 4134
-rw------- 1 root system 8192 Jun 27 15:29 bootlog
-r-xr-xr-x 1 root system 668 Oct 23 2001 bosinst.data
-rw-rw-r-- 1 root system 16384 Oct 23 2001 bosinstlog
-rw-r--r-- 1 bin bin 197318 Oct 23 2001 codepoint.cat
-rw--w--w- 1 root system 16384 Jun 28 10:06 conslog
-rw-r--r-- 1 root system 45478 Oct 23 2001 devinst.log
-rw-r--r-- 1 root system 86639 Jun 28 04:01 diag_log
-rw-r--r-- 1 root system 270990 Jun 28 10:30 errlog
-rwxrwxrwx 1 root system 2 Jan 11 11:22 errlogpbl
-r--r--r-- 1 bin bin 68422 Jun 27 15:10 errtmplt
-r-xr-xr-x 1 root system 11883 Oct 23 2001 image.data
-rw-r--r-- 1 root system 10230 Oct 23 2001 install_updates.log
-rw-r--r-- 1 root system 11748 Oct 23 2001 nim.script
-rw-r--r-- 1 root system 8192 Jun 21 12:20 nimlog
-rw-rw-rw- 1 root system 1343992 Apr 16 12:13 trcfile
[ ~ ]:

Thanks!
tl
 
Take a look at /etc/syslog.conf. This will tell you where your system log is. Make sure the logging level is set low enough so it will log when the process dies.
 
Another great suggestion - thanks! I enabled *.debug in /etc/syslog.conf, rebooted, and now see when an error written to the 'console' Alog:

0 Fri Jun 28 14:01:14 EDT 2002 Jun 28 14:01:14 Leg-sancl5 xntpd[10604]:
3.4y
0 Fri Jun 28 14:01:14 EDT 2002 Jun 28 14:01:14 Leg-sancl5 xntpd[10604]:
Clock init couldn't find kernel as either /vmunix or /unix

Is this a path problem?

Thanks, as ever.
tl
 
Just a thought..

do you have in the root directory a link.....

/unix to /usr/lib/boot/unix_up or /usr/lib/boot/unix_mp?
------------------------

cd /
ls -la
lrwxrwxrwx 1 root system 21 Feb 2 2000 unix -> /usr/lib/boot/unix_up -------------------------------------------------
 
It works! I created the link with:

ln -s /usr/lib/boot/unix_mp /unix

started xntpd, and it now works great! It has synch'd with my three ntp servers, and everything is fine.

Thank you very much, bi and aixqueen, for your time and help!

tl
 
one last note...make sure that the file /usr/lib/boot/unix_mp is not zero bytes...
Sometimes the file gets zeroed out by a full filesystem, or various other reasons... and that is sometimes why the link goes away...

If it is zero your system will reboot and appear to work, but if you try to generate a mksysb or a bosboot command it will fail.

So the link should have been there....but as I said make sure the file it is linked to is not zero...if it is you will have to restore that file from mksysb...or put a new level bos.mp on your system...

Glad it worked.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top