Many friends often forget the root password of the Linux system. What should I do if the Linux system forgets the root password? Reinstall the system? Of course not! Enter single-user mode and change the root password. (Recommended learning: linux tutorial)
The steps are as follows:
Restart the linux system
Press Enter within 3 seconds and the following interface will appear
Then enter e
Enter single at the end of the second line, there is a space. The specific method is to press the downward tip to move to the second line, and press "e" to enter the editing mode
Add single at the end and press Enter
Finally press "b" to start. After startup, you will enter single-user mode
You have now entered single-user mode, and you can change the root password. The command to change the password is passwd
The above is the detailed content of What should I do if I forget my Linux password?. For more information, please follow other related articles on the PHP Chinese website!