# rmuser seems to "hang" indefinitely for some users



## Kiki Novak (Nov 5, 2014)

Hi,

I have FreeBSD 10.0 amd64 running on one of my machines, and I'm currently reading through the (excellent) FreeBSD handbook and experimenting a lot.
It looks like the rmuser command does not work as expected. I created a bunch of users, and when I try to delete them, the rmuser command seems to "hang" indefinitely for some of them, and I have to hit Ctrl-C to get back to the command prompt... without knowing if the operation was a success or a failure. Here's what this looks like:


```
root@bernadette:~ #  cat /etc/passwd
...
nobody:*:65534:65534:Unprivileged user:/nonexistent:/usr/sbin/nologin
kikinovak:*:1001:1001:Nicolas Kovacs:/home/kikinovak:/bin/sh
glagaffe:*:1002:1003:Gaston Lagaffe:/home/glagaffe:/bin/sh
ahabian:*:1003:1004:Alexandre Habian:/home/ahabian:/bin/sh
kjoly:*:1004:1005:Karine Joly:/home/kjoly:/bin/sh
jktartempion:*:1005:1006:Jean-Kevin Tartempion:/home/jktartempion:/bin/sh
root@bernadette:~ #  rmuser jktartempion
Matching password entry:

jktartempion:*:1005:1006::0:0:Jean-Kevin Tartempion:/home/jktartempion:/bin/sh

Is this the entry you wish to remove? *y*
Remove user's home directory (/home/jktartempion)? *y*
Removing user (jktartempion): mailspool home passwd.
root@bernadette:~ # *rmuser kjoly*
Matching password entry:

kjoly:*:1004:1005::0:0:Karine Joly:/home/kjoly:/bin/sh

Is this the entry you wish to remove? *y*
Remove user's home directory (/home/kjoly)? *y*
Removing user (kjoly): mailspool home passwd.
root@bernadette:~ #  rmuser ahabian
Matching password entry:

ahabian:*:1003:1004::0:0:Alexandre Habian:/home/ahabian:/bin/sh

Is this the entry you wish to remove? *y*
Remove user's home directory (/home/ahabian)? *y*
Removing user (ahabian): mailspool home passwd
^C
root@bernadette:~ #  rmuser glagaffe
Matching password entry:

glagaffe:*:1002:1003::0:0:Gaston Lagaffe:/home/glagaffe:/bin/sh

Is this the entry you wish to remove? *y*
Remove user's home directory (/home/glagaffe)? *y*
Removing user (glagaffe): mailspool home passwd^C
root@bernadette:~ #
```

Any idea what's wrong here?


----------



## wblock@ (Nov 5, 2014)

Files locked by programs that are still running?


----------



## Kiki Novak (Nov 5, 2014)

That's strange, because I created these users just to experiment, but they never logged in - or I never `su`'ed to any of their accounts.


----------



## wblock@ (Nov 5, 2014)

I was just guessing, probably incorrectly.

An old BSD trick is to press ctrl-T while waiting for a process.  It will often show the status of the current program.  Sometimes it is not very helpful, but sometimes it can show what is taking so long.


----------



## Kiki Novak (Nov 5, 2014)

I gave it a spin on another machine, and everything went well. Strange.


----------

