# Adding a new "user account"



## setti (Jul 30, 2009)

Hello,

I have a problem with adding a new account through "User and group Management" window, when I want to create a new account I have a message : *The 'pw' command exited with unexpected status 74* !

What's wrong ? :q

Regards


----------



## graudeejs (Jul 30, 2009)

why won't you use
`$ adduser`


----------



## danger@ (Jul 30, 2009)

adduser is just a wrapper around pw anyway...


----------



## setti (Jul 30, 2009)

```
# adduser
```
doesn't work ! sorry


----------



## Oxyd (Jul 30, 2009)

setti said:
			
		

> *The 'pw' command exited with unexpected status 74*



sysexits(3) says status 74 is:
	
	



```
EX_IOERR (74)         An error occurred while doing I/O on some file.
```

pw(8) explains:
	
	



```
EX_IOERR
           o   Unable to rewrite configuration file.
           o   Error updating group or user database files.
           o   Update error for passwd or group database files.
```

So pw must be having problems writing a file -- make sure you are root; if you are sure you are root, check the permissions on /etc/passwd and /etc/group to verify that the permissions didn't get messed up somehow.


----------



## graudeejs (Jul 30, 2009)

check if root is mounted read-write


----------



## setti (Jul 30, 2009)

Oxyd said:
			
		

> So pw must be having problems writing a file -- make sure you are root; if you are sure you are root, check the permissions on /etc/passwd and /etc/group to verify that the permissions didn't get messed up somehow.



/etc/passwd :

```
root:*:0:0:Charlie &:/root:/bin/csh
toor:*:0:0:Bourne-again Superuser:/root:
daemon:*:1:1:Owner of many system processes:/root:/usr/sbin/nologin
operator:*:2:5:System &:/:/usr/sbin/nologin
bin:*:3:7:Binaries Commands and Source:/:/usr/sbin/nologin
tty:*:4:65533:Tty Sandbox:/:/usr/sbin/nologin
kmem:*:5:65533:KMem Sandbox:/:/usr/sbin/nologin
games:*:7:13:Games pseudo-user:/usr/games:/usr/sbin/nologin
news:*:8:8:News Subsystem:/:/usr/sbin/nologin
man:*:9:9:Mister Man Pages:/usr/share/man:/usr/sbin/nologin
sshd:*:22:22:Secure Shell Daemon:/var/empty:/usr/sbin/nologin
smmsp:*:25:25:Sendmail Submission User:/var/spool/clientmqueue:/usr/sbin/nologin
mailnull:*:26:26:Sendmail Default User:/var/spool/mqueue:/usr/sbin/nologin
bind:*:53:53:Bind Sandbox:/:/usr/sbin/nologin
proxy:*:62:62:Packet Filter pseudo-user:/nonexistent:/usr/sbin/nologin
_pflogd:*:64:64:pflogd privsep user:/var/empty:/usr/sbin/nologin
_dhcp:*:65:65:dhcp programs:/var/empty:/usr/sbin/nologin
uucp:*:66:66:UUCP pseudo-user:/var/spool/uucppublic:/usr/local/libexec/uucp/uuci
pop:*:68:6:Post Office Owner:/nonexistent:/usr/sbin/nologin
www:*:80:80:World Wide Web Owner:/nonexistent:/usr/sbin/nologin
nobody:*:65534:65534:Unprivileged user:/nonexistent:/usr/sbin/nologin
messagebus:*:556:556:D-BUS Daemon User:/nonexistent:/sbin/nologin
polkit:*:562:562:PolicyKit Daemon User:/nonexistent:/sbin/nologin
haldaemon:*:560:560:HAL Daemon User:/nonexistent:/sbin/nologin
cups:*:193:193:CUPS Owner:/nonexistent:/usr/sbin/nologin
setti:*:1001:0:Mohammed Setti:/home/setti:/bin/csh
```

/etc/group


```
wheel:*:0:root
daemon:*:1:
kmem:*:2:
sys:*:3:
tty:*:4:
operator:*:5:root
mail:*:6:
bin:*:7:
news:*:8:
man:*:9:
games:*:13:
ftp:*:14:
staff:*:20:
sshd:*:22:
smmsp:*:25:
mailnull:*:26:
guest:*:31:
bind:*:53:
proxy:*:62:
authpf:*:63:
_pflogd:*:64:
_dhcp:*:65:
uucp:*:66:
dialer:*:68:
network:*:69:
audit:*:77:
www:*:80:
nogroup:*:65533:
nobody:*:65534:
messagebus:*:556:
polkit:*:562:
haldaemon:*:560:
cups:*:193:
```


----------



## DutchDaemon (Jul 30, 2009)

Does this work?

[cmd=]cd /etc && pwd_mkdb -p master.passwd[/cmd]?


----------

