How to change the password on CentOS system

1) Remotely enter the system, log in as root user, press any key within 3 seconds to enter the following interface, and press the e key

 Description: e: Enter edit mode a: Change kernel options c: Enter command line mode

2) Select the second item, the line starting with kernel, press the e key to edit, add the number 1 or s, single at the end, press Enter and select b to start, you can directly enter the Linux single user mode.

3) You can see that you have entered the single-user mode. After entering, you are not required to enter a password. You can run runlevel to check the running level.

 

4) Start resetting the new password. Use passwd to change the root password. Enter the new password twice in succession. After the setting is completed, you need to reboot.

 

Guess you like

Origin blog.csdn.net/dexunyun/article/details/129948517