# Difficulty with user accounts



## imp (Dec 9, 2010)

I was installing mpd when it bailed throwing an error because

```
/: write failed, filesystem is full
pwd_mkdb: /etc/pwd.db to /etc/pwd.db.tmp: No space left on device
pw: passwd file update: No such file or directory
*** Error code 74

Stop in /usr/ports/audio/musicpd.
*** Error code 1

Stop in /usr/ports/audio/musicpd.
```
i ran df -h to check my filesystems and got


```
fbsdbox1# df -h
Filesystem     Size    Used   Avail Capacity  Mounted on
/dev/ad4s1a    496M    491M    -35M   108%    /
devfs          1.0K    1.0K      0B   100%    /dev
/dev/ad4s1e    496M    2.0M    454M     0%    /tmp
/dev/ad4s1f     88G    7.6G     73G     9%    /usr
/dev/ad4s1d    3.9G    173M    3.4G     5%    /var
linprocfs      4.0K    4.0K      0B   100%    /usr/compat/linux/proc
```

i attempted to make clean install again and an error popped up telling me the the user mpd already existed.
This is where i run into trouble aside from the 108% capacity and the -35M Availible despite the fact that i should still have 5MB left.

```
pw: user 'mpd' already exists
*** Error code 74

Stop in /usr/ports/audio/musicpd.
*** Error code 1

Stop in /usr/ports/audio/musicpd.
fbsdbox1# pw add user mpd
pw: user 'mpd' already exists
fbsdbox1# pw del user mpd
pw: no such user `mpd'
```
this simply makes no sense to me and i have no idea how to proceed.
thanks in advance for the help


----------



## rusty (Dec 9, 2010)

Regain free space on / by removing *.symbols in your kernel directory
`# rm -rf /boot/kernel/*.symbols`

If 'mpd' exists in master.passwd you could delete the entry and then
`# cap_mkdb /etc/master.passwd`
before [re]installing mpd again.


----------



## Beastie (Dec 9, 2010)

Make some room in the root partition, for example by removing all the symbols files in the /boot/kernel/ directory. Also make sure you don't have too much stuff in /root.

`% du -xh /`
will help you see what's taking up all the disk space.


----------



## imp (Dec 9, 2010)

*look before I leap*

what are these symbol files and why can i delete them with impunity?
just a link to somewhere that explains them would be fine.
I deleted several files from root that i had no need for and freed up enough room so that there was no longer a space limitation but even after removing the mpd entry using cap_mkdb the install still hangs saying that mpd exists.


----------



## rusty (Dec 9, 2010)

A search for FreeBSD kernel debugging symbols should get you started.

Sorry, `# pwd_mkdb /etc/master.passwd` instead of cap_mkdb.


----------



## imp (Dec 9, 2010)

It is still throwing an error message about mpd already being there. Should I reboot or load something after I reset the password db. there is no trace of mpd in /etc/master.pwd and I ran pwd_mkdb.


----------



## rusty (Dec 9, 2010)

Rebooting shouldn't be a problem. If 'mpd' persists to be a problem you could move /etc/pwd.db and try running `# pwd_mkdb` on /etc/master.passwd again.


----------



## imp (Dec 10, 2010)

that didn't seem to help either. still gives the error. I really don't know what's going wrong.


----------



## DutchDaemon (Dec 10, 2010)

Either run rmuser(8) on the mpd user, or simply delete it from /etc/master.passwd (and probably from /etc/group), followed by a [cmd=]cd /etc && pwd_mkdb -p master.passwd[/cmd]


----------



## imp (Dec 10, 2010)

I ran rmuser on mpd and the user doesn't exist in the password database but i knew that because i deleted the entry and also removed the group separately. The group caused no problems but pw still says that there both is and isn't a mpd  user.


----------



## DutchDaemon (Dec 10, 2010)

Again: delete it from /etc/master.passwd, followed by a `cd /etc && pwd_mkdb -p master.passwd`

When both master.passwd and passwd (rebuilt by above command) do not have an mpd user, there's no reason for anything to assume that there is.


----------



## imp (Dec 11, 2010)

*And yet...*

it persists

```
fbsdbox1# cd /etc
fbsdbox1# pwd_mkdb -p master.passwd
fbsdbox1# cd /usr/port/audio/musicp
/usr/port/audio/ not found

fbsdbox1# cd /usr/ports/audio/musicpd/ && make install clean
===>  Installing for musicpd-0.15.12_1
===>   musicpd-0.15.12_1 depends on executable: pkg-config - found
===>   musicpd-0.15.12_1 depends on file: /usr/local/lib/gio/modules/libgiofam.so - found
===>   musicpd-0.15.12_1 depends on shared library: mad.2 - found
===>   musicpd-0.15.12_1 depends on shared library: curl.6 - found
===>   musicpd-0.15.12_1 depends on shared library: FLAC.10 - found
===>   musicpd-0.15.12_1 depends on shared library: vorbis.4 - found
===>   musicpd-0.15.12_1 depends on shared library: faad.2 - found
===>   musicpd-0.15.12_1 depends on shared library: mp3lame.0 - found
===>   musicpd-0.15.12_1 depends on shared library: audiofile.0 - found
===>   musicpd-0.15.12_1 depends on shared library: zzip.13 - found
===>   musicpd-0.15.12_1 depends on shared library: iso9660.7 - found
===>   musicpd-0.15.12_1 depends on shared library: avcodec.1 - found
===>   musicpd-0.15.12_1 depends on shared library: avformat - found
===>   musicpd-0.15.12_1 depends on shared library: avutil.1 - found
===>   musicpd-0.15.12_1 depends on shared library: mms.0 - found
===>   musicpd-0.15.12_1 depends on shared library: id3tag.0 - found
===>   musicpd-0.15.12_1 depends on shared library: pulse.0 - found
===>   musicpd-0.15.12_1 depends on shared library: shout.5 - found
===>   musicpd-0.15.12_1 depends on shared library: glib-2.0.0 - found
===>   Generating temporary packing list
===>  Checking if audio/musicpd already installed
===> Creating users and/or groups.
Using existing group `mpd'.
Creating user `mpd' with uid `137'.
pw: group `137' does not exist
*** Error code 67

Stop in /usr/ports/audio/musicpd.
*** Error code 1

Stop in /usr/ports/audio/musicpd.
```
/etc/master.passwd

```
# $FreeBSD: src/etc/master.passwd,v 1.40.22.1.4.1 2010/06/14 02:09:06 kensmith E
xp $
#
root:$1$YDO5w0A2$W2yV.VHMJUqryVr71s5jD1:0:0::0:0:Charlie &:/root:/bin/csh
toor:*:0:0::0:0:Bourne-again Superuser:/root:
daemon:*:1:1::0:0:Owner of many system processes:/root:/usr/sbin/nologin
operator:*:2:5::0:0:System &:/:/usr/sbin/nologin
bin:*:3:7::0:0:Binaries Commands and Source:/:/usr/sbin/nologin
tty:*:4:65533::0:0:Tty Sandbox:/:/usr/sbin/nologin
kmem:*:5:65533::0:0:KMem Sandbox:/:/usr/sbin/nologin
games:*:7:13::0:0:Games pseudo-user:/usr/games:/usr/sbin/nologin
news:*:8:8::0:0:News Subsystem:/:/usr/sbin/nologin
man:*:9:9::0:0:Mister Man Pages:/usr/share/man:/usr/sbin/nologin
sshd:*:22:22::0:0:Secure Shell Daemon:/var/empty:/usr/sbin/nologin
smmsp:*:25:25::0:0:Sendmail Submission User:/var/spool/clientmqueue:/usr/sbin/no
login
mailnull:*:26:26::0:0:Sendmail Default User:/var/spool/mqueue:/usr/sbin/nologin
bind:*:53:53::0:0:Bind Sandbox:/:/usr/sbin/nologin
proxy:*:62:62::0:0:Packet Filter pseudo-user:/nonexistent:/usr/sbin/nologin
_pflogd:*:64:64::0:0:pflogd privsep user:/var/empty:/usr/sbin/nologin
_dhcp:*:65:65::0:0:dhcp programs:/var/empty:/usr/sbin/nologin
uucp:*:66:66::0:0:UUCP pseudo-user:/var/spool/uucppublic:/usr/local/libexec/uucp
/uucico
pop:*:68:6::0:0:Post Office Owner:/nonexistent:/usr/sbin/nologin
www:*:80:80::0:0:World Wide Web Owner:/nonexistent:/usr/sbin/nologin
nobody:*:65534:65534::0:0:Unprivileged user:/nonexistent:/usr/sbin/nologin
conor:$1$9laPfU0q$wQZTPD3y.mrlo3pD.sLRf0:1001:0::0:0:User &:/home/conor:/usr/loc
al/bin/zsh
messagebus:*:556:556::0:0:D-BUS Daemon User:/nonexistent:/usr/sbin/nologin
polkit:*:562:562::0:0:PolicyKit User:/nonexistent:/usr/sbin/nologin
haldaemon:*:560:560::0:0:HAL Daemon User:/nonexistent:/usr/sbin/nologin
avahi:*:558:558::0:0:Avahi Daemon User:/nonexistent:/sbin/nologin
pulse:*:563:563::0:0:PulseAudio System User:/nonexistent:/usr/sbin/nologin
```


----------



## rghq (Dec 11, 2010)

The last error message is group related, even if master.passwd, pwd_mkdb etc. are fine.

Tried a:

getent passwd
getent group

And checked the output ? The manually created a "test" group to see if the command runs without problems ?


----------

