Because a friend's Linux password forgot, let me help to fix,
After the feeling, this method may still be used later,
Summarize the record and make it easy to use later.
The Linux version is: Ubuntu 14.04
The first step is booting to grub
The second step into Ubuntu advanced settings is as follows
Step three to Recovery mode recovery Model (note that this step is to press e instead of carriage return)
This is a post-entry effect.
Fourth step to find RO recovery mode to modify it to be RW single Init=/bin/bash
And then Ctrl+x will be able to enter
Some of the interfaces are as follows:
Under this interface you use passwd "root"
The root password can be modified
If the machine is multi-user, you forget that you want to modify the user's user name,
You can use this command to find: Cat/etc/shadow
This command can find the user name,
You can then continue to modify it with passwd.
Normal does not forget the root user password, can be changed under the root user,
Forget the root password, forget login password can use this way.
How to modify Linux forgot login/root password