# redis can not run (su: unknown login: redis /usr/local/etc/rc.d/redis: WARNING: failed to start redis)



## andrian (Jan 5, 2020)

Hi, i have:

```
# uname -a
FreeBSD freebsd02 12.1-RELEASE-p1 FreeBSD 12.1-RELEASE-p1 Core  amd64
```
Install:
/usr/ports/databases/redis
run:

```
root@freebsd02:/ # /usr/local/etc/rc.d/redis start
Starting redis.
su: unknown login: redis
/usr/local/etc/rc.d/redis: WARNING: failed to start redis
root@freebsd02:/ #
```
How fix this problem?


----------



## richardtoohey2 (Jan 5, 2020)

How exactly did you install redis?  Looks like it needs an account "redis" to be created and that hasn't happened.


----------



## andrian (Jan 5, 2020)

I fix this. (pwd_mkdb -p /etc/master.passwd detail on https://forums.freebsd.org/threads/cannot-add-user-or-rebuild-password-database.47546/)

There was a problem in the file


```
root@freebsd02:/ # cat /etc/passwd
# $FreeBSD: releng/12.1/etc/master.passwd 337882 2018-08-15 23:18:34Z brd $
#
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/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
unbound:*:59:59:Unbound DNS Resolver:/var/unbound:/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/uucico
pop:*:68:6:Post Office Owner:/nonexistent:/usr/sbin/nologin
auditdistd:*:78:77:Auditdistd unprivileged user:/var/empty:/usr/sbin/nologin
www:*:80:80:World Wide Web Owner:/nonexistent:/usr/sbin/nologin
ntpd:*:123:123:NTP Daemon:/var/db/ntp:/usr/sbin/nologin
_ypldap:*:160:160:YP LDAP unprivileged user:/var/empty:/usr/sbin/nologin
hast:*:845:845:HAST unprivileged user:/var/empty:/usr/sbin/nologin
nobody:*:65534:65534:Unprivileged user:/nonexistent:/usr/sbin/nologin
andrian:*:1001:1001:andrian:/home/andrian:/bin/csh
redis:*:1002:535:redis:/home/redis:/usr/sbin/nologin
```
But
`root@freebsd02:/ # pw usershow -n redis
pw: no such user `redis'`


----------

