CentOS 7 tips for resetting the root password

  
                

CentOS system operation, sometimes need to reset the root password, and CentOS 7 root password reset method is slightly different from the previous versions, many people do not know how to reset the root password, the following small series for everyone Introduce how CentOS 7 resets the root password. Let's learn together.

Procedure:

1 - grub boot menu, select the option to start editing

2 - e Press keyboard keys to enter the editing interface

3 - Linux find the line 16, to the ro rw init = /sysroot /bin /

4 - now press Control + x, single-user mode < Br>

5 - Now, you can use the following command to access the system

chroot /sysroot

6 - reset password

passwd root

7 - Update system information

touch /.autorelabel

8 - Exit chroot

exit

9 - Restart your system

reboot

The above is the way CentOS 7 resets the root password. This method is only applicable to the CentOS 7 version. Other versions of the root reset are different and I hope to help you.

Copyright © Windows knowledge All Rights Reserved