Linux forgot root password

Source: Internet
Author: User

Centos:

1. Press "E" in the Grub Boot interface to enter edit mode

2. Choose Kernel/... And then in the "E"

3. Add "single" to the back. Press "B" again.

4. Enter: "passwd root" to enter the new root password

5, reboot, done

Ubuntu:1, press "E" in the Grub Boot interface to enter edit mode

2, find linux/boot/vm.......ro recovery \nomodeset,

Step 1: Remove recovery \nomodeset

Step 2: At the end of this line add quiet splash rw Init=/bin/bash

3, F10 Save exit

4. Enter: "passwd root" to enter the new root password

5, reboot, done

Linux forgot root password

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: info-contact@alibabacloud.com 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.