2 ntpd (5.3-STABLE-SNAP001)
Kevin Oberman
oberman at es.net
Wed Mar 2 23:07:56 GMT 2005
> Date: Wed, 2 Mar 2005 16:07:04 +0100 (CET)
> From: "Thomas Krause" <freebsd-stable at chef-ingenieur.de>
> Sender: owner-freebsd-stable at freebsd.org
>
> Hello,
> when starting ntpd at boot time, I've 2 ntpd's running:
>
> gate:/ # ps auxw | grep ntp
> root 407 0.0 0.7 2944 1752 ?? Ss 3:54PM 0:00.02 /usr/sbin/ntpd
> -p /var/run/ntpd.pid -f /var/db/ntpd.drift
> root 417 0.0 0.7 2944 1776 ?? S 3:54PM 0:00.00 /usr/sbin/ntpd
> -p /var/run/ntpd.pid -f /var/db/ntpd.drift
>
> gate:/ # ntpq
> ntpq> peers
> No association ID's returned
>
> After restarting, I've one daemon and all is running fine:
>
> gate:/ # /etc/rc.d/ntpd restart
> Stopping ntpd.
> Starting ntpd.
>
> gate:/ # ps auxw | grep ntp
> root 566 0.0 0.7 2944 1784 ?? Ss 4:04PM 0:00.02 /usr/sbin/ntpd
> -p /var/run/ntpd.pid -f /var/db/ntpd.drift
>
> Any idea why? I' running 5.3-STABLE-SNAP001.
Either you have two commands to start ntpd in /etc/rc.d or (more likely)
the parent process is never exiting. When ntpd starts, it forks a child
process (the daemon) and exits. I have seen cases where the parent
process never exits because the child never properly starts.
That said, I have never seen this happen on a FreeBSD system, so it may
be that you are starting it twice. But this seems a bit unlikely as the
second daemon should exit immediately because the network socket is
already in use. But it's possible that they are stating so close
together that a race condition is locking things up. (Just speculation.)
--
R. Kevin Oberman, Network Engineer
Energy Sciences Network (ESnet)
Ernest O. Lawrence Berkeley National Laboratory (Berkeley Lab)
E-mail: oberman at es.net Phone: +1 510 486-8634
More information about the freebsd-stable
mailing list