Linux to modify the root password and Linux forgot root password after the method to retrieve the password _linux

Source: Internet
Author: User

Log in as root, execute:

Copy Code code as follows:

# passwd username (change password)
# Useradd User name (add user)

The specific examples are as follows:

Copy Code code as follows:

[Root@bogon ~]# passwd Root
Changing password for user root.
New UNIX Password:
Bad Password:it are based on a dictionary word
Retype new UNIX Password:
Passwd:all authentication tokens updated successfully.

The method of root password retrieve under Linux

Linux Root has the supremacy of power, once the root password forgotten or stolen, is a very headache, then how to retrieve the root password, I summed it up as follows:

A Linux System Password cracking

1. Enter edit mode by E in the Grub options menu

2. Edit kernel that line/init 1 (or/single)

3. Restart by B

4. After entering, execute the following command

Copy Code code as follows:

root@ #passwd root (password with root configured)
Enter new UNIX password: Enter a password
root@ #init 6

(ii) Debian Linux system password cracking

1. In the Grub Options menu ' Debian gnu/linux,... (recovery mode) ', enter edit mode by E

2. Edit kernel the line of the RO single to the RW single init=/bin/bash, press B to perform the reboot

3. After entering, execute the following command

Copy Code code as follows:

root@ (None) #mount-A
root@ (none) #passwd root
root@ (None) #reboot

Three Freebsd System Password cracking

1. Boot into the Guide menu

2. Select each item (press 4) to enter Single-user mode

3. Enter a list of commands after entering

Copy Code code as follows:

root@ #mount-A
root@ #fsck-y
root@ #passwd (Change Password command)

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.