Personal tools
You are here: Home Team Members Re Alvarez How to reset forgotten root password

How to reset forgotten root password

by realz last modified Mar 11, 2008 12:44 PM
— filed under:

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.

Here is an excellent guide if you do not know anything about runlevels by bobjensen


This assumes that you are running a standard fedora installation with grub. Although this guide is written keeping fedora 8 in mind, this should also work with other releases.


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.
    grub append> ro root=LABEL=/ rhgb quiet
  5. Add '1' to that line. So the whole prompt line would look something like
    grub append> ro root=LABEL=/ rhgb quiet 1
  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.
    # passwd
  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 #fedora on

Added Reading

Document Actions
Log in

Forgot your password?
New user?