Solved Required ntpd user is missing

I just found out that I can't make installworld because 'required ntpd user is missing'. Should this user have not been added as part of a recent upgrade?

Is there a recommended way to add this user, so I don't screw things up?
 
Don't know for sure just how I got it, but I have an ntpd user in /etc/passwd:
Code:
$ grep ntpd /etc/passwd
ntpd:*:123:123:NTP Daemon:/var/db/ntp:/usr/sbin/nologin
$
I think it's probably from selecting the option to update the time when rebooting the system, in the initial FreeBSD install. I'm guessing it likely might be this daemon process I see logging its activities in dmesg -a:
Code:
$ dmesg -a |grep ntpd
11 Mar 01:14:33 ntpdate[611]: step time server 173.71.69.215 offset -1.127200 sec
$
This link is a FreeBSD reference to it. I'm guessing it might even get created automatically if you run sysrc ntpdate_enable=YES or sysrc ntp_update and then reboot.
 
If I'm not mistaken it should have been the case by mergemaster -p (manual merges of /etc/group and /etc/master.passwd - if you haven't skipped them by IGNORE_FILES in /etc/mergemaster.rc).

But you can add it yourself by:
Code:
pw groupadd ntpd -g 123
pw useradd ntpd -u 123 -g ntpd -h - -d /var/db/ntp -s /usr/sbin/nologin -c "NTP Daemon"
Then rerun make installworld.
 
I'm guessing it likely might be this daemon process I see logging its activities in dmesg -a:
Code:
$ dmesg -a |grep ntpd
11 Mar 01:14:33 ntpdate[611]: step time server 173.71.69.215 offset -1.127200 sec
$
This link is a FreeBSD reference to it. I'm guessing it might even get created automatically if you run sysrc ntpdate_enable=YES or sysrc ntp_update and then reboot.


Code:
root@Server:~/projects/GFH# dmesg -a |grep ntpd
Security policy loaded: MAC/ntpd (mac_ntpd)
Starting ntpd.
su: unknown login: ntpd
/etc/rc: WARNING: failed to start ntpd

After running sysrc ntpdate_enable=YES and rebooting...
Code:
root@Server:~ # dmesg -a |grep ntpd
14 Mar 00:03:14 ntpdate[630]: step time server 85.199.214.100 offset -3600.663888 sec
Security policy loaded: MAC/ntpd (mac_ntpd)
Starting ntpd.
su: unknown login: ntpd
/etc/rc: WARNING: failed to start ntpd

but in my logs I checked /etc/passwd and found:-
Code:
ntpd:*:123:123:NTP Daemon:/var/db/ntp:/usr/sbin/nologin


so I don't really know what is going on...😕
 
I really don't either. Have you tried running make installworld again yet?

Yes, it is running again from the beginning, and I expect that after seven hours I will get the same error, since it looks as though the ntpd user did exist when I first ran it...😡
 
Fingers crossed... ☂

Same thing happened again :(

I'm beginning to think that it's not the ntpd user but the location of passwd which is causing the problem...

Maybe this is related PR 231334

I also noticed in my build log for make installworld TARGET_ARCH=arm DESTDIR=/var/nfsroot:-

Code:
cd /usr/src/etc;  install -N /usr/src/etc -o root -g wheel -m 644  group  login.access  rc.bsdextended  rc.firewall  termcap.small rc.sendmail /var/nfsroot/etc;  install
 -N /usr/src/etc -o root -g wheel -m 600  master.passwd /var/nfsroot/etc;
install: target directory `/var/nfsroot/etc' does not exist

So maybe I'm not understanding how the process works. I just created and empty subdirectory - /var/nfsroot/ and assumed that make installworld would dump its output there. Have I got that wrong?
 
Don't know why but it's always the same problem that comes from time to time and you already encountered it. I guess that the passwords database is out of sync. Try: pwd_mkdb -p /etc/master.passwd

This is the correct answer. It always works. In fact, it works 99.9% of the times you encounter the problem "user went away" in ports/package installations.
 
Don't know why but it's always the same problem that comes from time to time and you already encountered it. I guess that the passwords database is out of sync. Try: pwd_mkdb -p /etc/master.passwd

To be honest I didn't think it would work, but it did.🍺
 
This is the correct answer. It always works. In fact, it works 99.9% of the times you encounter the problem "user went away" in ports/package installations.

Well when an Administrator, Staff member, Moderator, Developer suggests something, it's time to listen! :)👍
 
Back
Top