Monday, July 8, 2013

Puppet: usermod: user is currently logged in

If you are provisioning a node, and this entails changing something os a user (in my case, the home directory), usermod could fail with the message

"usermod: user BLA is currently logged in"

Run "who" or "w" to determine if this is the case.

If not, run "ps -ef -grep BLA" or better "ps U BLA" to determine if the user is running processes. If yes, kill them all.



No comments: