In this post will guide you simple steps to resetforgotten root passwordinRHEL,CentOSandFedoraLinux with example. There are various ways to reset root password which are.

  1. Booting intosingle usermode.
  2. Usingboot diskand editpasswdfile.
  3. Mountdriveto another system and changepasswdfile.

Here, in this article we are going to review “Booting into single user mode” option to reset forgottenrootpassword.

Cautious:We urge to take backup of your data and try it out at your own risk.

STEP 1. Boot Computer and Interrupt while booting atGRUBstage hitting ‘arrow‘ keys or “space bar“.

How to Reset Forgotten Root Password in RHEL/CentOS and Fedora

Booting GRUB Stage

STEP 2. Type ‘a‘ to modify kernel argument. Anytime you can cancel typing ‘ESC‘ key.

How to Reset Forgotten Root Password in RHEL/CentOS and Fedora

Modify Kernel Argument

STEP 3. Append1at the end of “rhgb quiet” and press “Enter” key to boot into single user mode.

How to Reset Forgotten Root Password in RHEL/CentOS and Fedora

Append 1 at the Screen

STEP 4. Type command “runlevel” to know the the runlevel where you are standing. Here “1 S” state that your are in a single user mode.

How to Reset Forgotten Root Password in RHEL/CentOS and Fedora

Type Command runlevel

STEP 5. Type ‘passwd‘ command without username and press ‘Enter‘ key in command prompt. It’ll ask to supply new root password and re-type the same password for confirmation. “Your are Done” Congratulation!!!

How to Reset Forgotten Root Password in RHEL/CentOS and Fedora

Type passwd Command

What ifGRUB bootloader is password protected?We’ll cover in our next article, how to protectGRUBwith password and reset the same. Stay tuned…

If you find this article is helpful, or you may have some comments or query about it please feel free to contact with us through below comment box.

相关文章:

  • 2021-11-06
  • 2021-04-17
  • 2021-10-10
  • 2021-10-05
  • 2021-11-29
  • 2022-12-23
  • 2021-10-22
猜你喜欢
  • 2021-11-06
  • 2021-11-15
  • 2022-12-23
  • 2021-12-01
  • 2022-12-23
  • 2021-11-06
  • 2022-12-23
相关资源
相似解决方案