Share & learn

Through Innovative Digital Library

How to delete or remove the password to the user account in linux?

How to delete or remove the password to the user account in linux? It will help you when the user forget the password to login. By using this we can login to user account with out password.
 



Answers

Posted by chandu on December 8th 2017 06:02 AM

Some times you require to set passwordless logins to a user for auto logins, shell scripting so that you no need to provide any password. This can be achieved by using passwd command with -d option which deletes already assigned password.

Syntaxpasswd -d username

Posted by chandu on December 8th 2017 06:07 AM

If you want to check whether the password is assigned or not for user, the run the following command.

#cat /etc/shadow

Posted by chandu on December 8th 2017 06:11 AM

Now removing the password to the user5 by using following command. once if delete password to the user account , then this user can login to this account without password.

#passwd –d user5

Posted by chandu on December 8th 2017 06:14 AM

If you want to check all the changes see in /etc/shadow file. Now check the /etc/shadow file , the password is removed.

Answer Question

Your email address will not be published. Required fields are marked *

  • Minimum 20 character
ZOTF

related questions

Most liked questions

Most answered questions

Login
ZOTF Refresh
Register
ZOTF Refresh
Forgot password
Ask a Question
Minimum 20 character
Minimum 20 character
Reply
Minimum 20 character
ZOTF Refresh