How to reset a forgotten Ubuntu password

Sometimes you might have experienced a situation where you forgot your Ubuntu login password. I have came across such a situation. This post is about resetting a forgotten login password in Ubuntu.


Resetting a forgotten password in Ubuntu is very easy with the help of root-shell. All you have to do is to follow these simple steps.

Firstly you have to reboot your system, and press the ESC key when GRUB starts loading. From the menu, select the ‘Advanced options for Ubuntu‘ as shown.



Now select the ‘recovery mode‘ option from the menu.


From the recovery menu, select the option ‘root‘ which opens the root-shell prompt.


Now type the following commands and enter your new password when prompted,

mount -rw -o remount /
passwd <username>
reboot -f

For example, I have to reset the password for the username ‘greetz’. Then my command will be like,

mount -rw -o remount /
passwd greetz
reboot -f


Note: If you skip the command ‘mount -rw -o remount /’ you might get ‘Authentication token manipulation error’.


That’s it, you can again login with your new password.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s