To lock a user account on linux, you can use the passwd command.
The command is,
sudo passwd -l usernameFor example, to lock the user 'linda', so 'linda' can not login to the system anymore,
sudo passwd -l lindaLocking password for user linda. passwd: Success
Now you can try to login as 'linda' and you will see that you login is disabled.
No comments:
Post a Comment