Ubuntu forgot root password what to do? What to do if the average user forgets
The first method:
No matter if you have a root account or if you forgot your password, you will never have a problem!
1. Restart Ubuntu, then long press SHIFT to enter the Grub menu;
2. Select the second advanced mode recovery modes to enter
3, enter Recovery menu interface, select root Drop to root shell prompt, that is, to get root permissions
4. In the command line # after typing Cat/etc/shadow view the user name (if you forget the username)
5, typing: passwd "user name" and then two times the password can modify the user name password.
In addition, to change the root password, you can use the following method:
To modify the root password operation: #passwd
Enter new password: #
Enter password again: #
This is to set the root password, if it is set other user password use command: passwd user name can be
6, press Ctrl+alt+del Restart the system, complete.
Add : If your ordinary users do not forget, so good to do, remember we still have a strong sudo?
1, enter the terminal #sudo su root and then enter the password of the ordinary user, and temporarily get the root account permissions, but also into the root account;
At this time we can do whatever it is, do not believe that you switch several times the account, look at the line;
2, this is what we can do all only the root user can do, including modifying the root user's password, all is possible.
Ubuntu Forgot Password Solution