Change the administrator password in single-user mode in Linux
Use CentOS 6.6 in Linux
1. Press e or enter to enter the GRUB Startup Menu after starting the instance, as shown in figure;
2. Press e to enter the editing mode, and move the up/down key to switch to the 2nd line of kernel;
3. Press e to enter the kernel to edit the command line. For example, enter single, s, or 1
After entering the information, press enter to save and return to the upper-level Startup menu. Press B to start the system.
4. You do not need to enter the administrator password to start the system. In single-user mode, you can run the passwd command to change the administrator password;
5. single-user mode running level
Enter 1. The running level is displayed
[Root @ yong ~] # Runlevel
1 S
The input s or single running level is displayed
[Root @ yong ~] # Runlevel
N S
In single-user mode, the network cannot be connected, which is equivalent to Windows security mode.
This article permanently updates the link address: