Solution for Linux to forget the root password (image and text)

Source: Internet
Author: User
This article mainly introduces how to forget the root password for Linux. For more information, see

How does one forget the root password in Linux? This situation is not very common, but some careless administrators do not log on to the system for a long time, and they will forget the password. At this time, if it is remote management, it would be the same. If the linux host is on your side, it will be saved. Follow these steps:


1. after the system is restarted, the GRUB interface appears on the boot loader menu. use the up and down arrow keys to select the system you forgot the password and type "e" to enter the editing mode.

2. Next, you can see the image shown in. then, you can use the up and down keys to select the latest kernel (the second line is the kernel .......), then press "e.

3. add a space after the rhgb quiet on the editing page, type "single", or enter "1" of the number and press enter to confirm.

4. press enter and press the "B" key to start the single-user mode. here, modify the root password.

5. after the restart, the root password is changed!

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.