In an environment where many users are using the same server, it is important to perform some basic account maintenance tasks. These include locking accounts when they are unneeded for a longer time, unlocking an account, and reporting the password status. Also, an administrator can force a user to change his password on the first occasion. To perform these tasks, the passwd command has several options available:
-l: This enables an administrator to lock an account; for example, passwd -l jeroen will lock the account for user jeroen.
-u: This unlocks an account that has been locked before.
-S: This reports the status of the password for a given account.
-e: This forces the user to change her password on her next login.
Was this article helpful?