You can reset the root password in case you have forgotten it. For this we use boot options in grub. We will boot in runlevel 1 for this purpose. Runlevel 1 is Single User mode.


This assumes that you are running an official Centos graphical installation with grub. This guide should also be fully compatible with Fedora and RHEL.


Doing the work

  1. Restart your computer.
  2. When the grub options appear (the menu that lets you select multiple kernels, in case you have multiple kernels) press Escape key.
  3. When you press the Escape key you will reach in the kernel selection menu.
  4. Select the appropriate kernel you want to boot in and press ‘a’ (without quotes). You will have a prompt now. The prompt will be something like this.
  5. Add ‘1’ to that line. So the whole prompt line would look something like
  6. Now let the computer boot. Once booted up, you will get a prompt like
  7. Enter passwd here. passwd is the command used to change the password for a user.
  8. The system will ask you for your new password, enter it twice and you are done.
  9. Reboot your machine and let it boot normally.


More Information 


We test this stuff on our own machines, really we do. But you may
run into problems, if you do, come to #centos on

Added Reading

Last Modified: 17 Oct, 2010 at 18:39:18