Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 17 Mar 2019 00:02:32 +0100
From:      Polytropon <freebsd@edvax.de>
To:        B J <va6bmj@gmail.com>
Cc:        freebsd-questions <freebsd-questions@freebsd.org>
Subject:   Re: Upgraded 11.2 -> 12.0, ntpd Won't Start
Message-ID:  <20190317000232.58fbb60b.freebsd@edvax.de>
In-Reply-To: <CAP7QzkN7Y-7_Df6A%2BwWvfDthXTEkgxGVUA-KeQqKi8OWncBqXA@mail.gmail.com>
References:  <CAP7QzkMqhRg%2B=1z0vzk%2BAA50A=TEnazAc-t4rMUDLTsBGA__1A@mail.gmail.com> <CAP7QzkN7Y-7_Df6A%2BwWvfDthXTEkgxGVUA-KeQqKi8OWncBqXA@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, 16 Mar 2019 22:39:07 +0000, B J wrote:
> I ran:
> 
> pwd_mkdb -p /etc/master.passwd
> 
> on one of my computers and rebooted it when it was done.  I got the
> following message in the startup output:
> 
> ntpd[755]: pid file /var/db/ntp/ntpd.pid: Permission denied
> 
> I checked the file and found that the file has the number 789 in it.
> 
> By comparison, I have two systems that have fresh installations of
> FreeBSD 12.0.  Neither of them had the problem with ntpd that I
> mentioned in my original post.  I just checked the file on one of them
> and found that it has the number 885.
> 
> My question, now, is this:  is the condition mentioned in the message
> I got on the upgraded machine a problem?  Is the difference in the
> ntpd.pid files something to be concerned about?

The .pid file contains the process identification ("PID")
refering to the ntpd process. If you run the command

	# ps aux | grep ntpd

you should see that number in the 2nd column.

However, the error message seems to indicate a permission problem
for that file, i. e., the ntpd process cannot (re)write that file.
Check the permissions:

	# ls -l /var/db/ntp/ntpd.pid

It should have the owner and group set correctly for the "new"
environment (the one with the dedicated ntpd user account). It
could also be a problem with the directory the file resides in.
Check that one with:

	# ls -ld /var/db/ntp

Again, make sure the owner and group (as well as the permission
bits) are set correctly.



> Meanwhile, the computer's clock appears to be running properly as I
> reset my watch and the both are synchonized, so it seems that problem
> has been resolved.

The ntpd service will be started, but the process file that
probably contains a wrong PID could lead to problems if you
want to restart the service.



-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20190317000232.58fbb60b.freebsd>