Ubuntu Geek

Ubuntu Linux Tips,Howtos&Tutorials|Feisty,Gutsy,Hardy,Intrepid

  • RSS Feed

    subscribe to the ubuntu Geek RSS feed


  • Sponsor

  • Categories

  • Meta

  • Sponsor

  • Archives

  • Support Ubuntugeek

    Amount $:
    Website(Optional):


  • Favourite Sites

How-To Recover password under Ubuntu

Posted by admin on September 25th, 2007 Email This Post Email This Post

If you forgot you password for your ubuntu system you can recover using the following steps

Turn your computer on.

Press ESC at the grub prompt.

Press e for edit.

Highlight the line that begins kernel ………, press e

Go to the very end of the line, add rw init=/bin/bash

press enter, then press b to boot your system.

Your system will boot up to a passwordless root shell.

Type in passwd username

Set your password.

Type in reboot

Share/Save/Bookmark

If you want to be notified the next time we write something please subscribe to our RSS feed.Thanks for Visiting!

Related Articles

20 Responses to “How-To Recover password under Ubuntu”

  1. Sean Chambers Says:

    You used to be able to type in the boot command: “linux single” and it would kick you to a root prompt. Not sure if this still works or not though.

  2. Kubunteando Says:

    Very nice step list.

    Unfortunately that can be done because of a “huge” security issue with the typical Linux installations. Because using this same procedure you can also change the “root” password. So basically be aware that from your console anyone with some basic knowledge of Linux can enter in your computer. So don’t assume your data is that safe. I don’t store that important data in my computer, so I have not looked around for some solution. The BIOS password is not enough. So maybe some extra password in GRUB before entering in edition mode?

  3. the polarizer Says:

    @Kubunteando: Protecting from edit kernel parameter lines or from complete menu selections in grub can be done by using “password” and “lock” directives in grub configuration file (nornally /boot/grub/menu.lst).

    Check this link: http://www.gnu.org/software/grub/manual/html_node/password.html#password

    my 2 cents - the polarizer

  4. Kubunteando Says:

    To The Polarizer

    Thanks. I will try it.

  5. Fr33d0m Says:

    I guess it is time to switch back to a secure OS like windows. I can’t believe such a glaring security hole exists. I’m glad I at least wasn’t stupid enough to claim that Linux was more secure than windows.

  6. Kubunteando Says:

    It depends what is the type of security you value.
    I value that when I access my bank on the Internet I feel safe. That I did not get any “keyloggers” that steal my passwords, and I did not get that malware that who knows what is spying/doing while I am browsing the Net. That feeling of security I have it with Linux.

    I never access my bank account under Windows.
    Linux is far more secure than Windows.

    Telling that Windows is secure is a really good joke! :-)

  7. Murtadh Altarouti Says:

    Yesterday I forgot my password, and after searching about a way, all what I needed to do is just pressing Esc to enter Grub to the kernel then write this:passwd userName (replace the userName with the account name) and you wil be asked to wright a new password

  8. shirteesdotnet Says:

    So much for security!

  9. Someone Says:

    Well it all depends because if someone has physical access, they can just crack the windows password with Knoppix or another live cd by mounting your windows partition. So at least you can prevent this with a bootloader password.

  10. Someone Says:

    Well it all depends because if someone has physical access, they can just crack the windows password with Knoppix or another live cd by mounting your windows partition. So, at least you can prevent this with a bootloader password.

  11. JD Says:

    To all the windows trolls, it is as (in)secure as you choose it to be…
    Just configure grub in a secure way (that prevents edits by example)…
    Amazing, right…?! ^_^

  12. brittany Says:

    FOMG. What a huge security hole. Thanks for the warning. I had no idea this was possible.

    It is possible to password-protect the interactive startup. Follow the link to find out how to put a password on GRUB, and lock certain boot options [like recovery mode]

    http://www.gnu.org/software/grub/manual/html_node/Security.html

  13. vegard jorgensen Says:

    wow.. fr33d0m is mentally retarded! to say windows is more secure than linux is like saying hell is a better place than haven..
    sorry for being so nasty, but my dad is a propaganda hitler dude when it comes to picking linux over windoze!

    so.. before making a statement like that, go check the facts, a nice Python programmed firewall running in linux will make you
    impossible to be found .. and also, i think you would have be booting the machine when he/she tries to hack you?? im unsure..

    LINUX POWAH!! PLEASE BRING GAMING TO LINUX!!

  14. alan Says:

    To the gamer guy, you do realize that linux has awesome games (nexuiz..also is cross-platform for the windows users)

  15. n00b Says:

    This is how to reset your password; not how to recover it…

  16. Linux Boxer Says:

    I have ubuntu 7. I tried to reset passwd and found two kernel lines….ummm, which one to use? OK, the second one got me to a prompt, but typing a new passwd allowed me one letter only, said it was changed, but no, wrong wrong wrong, no sir, didn’t work. no go. Ummm, help?

  17. Linux Boxer Says:

    I need to update linux and can’t without a password. I don’t have a “questions.dat” file, so finding it there isn’t an option. I need it changed, not recovered, not how to change from the old one to a new one, not how to type passwd at the prompt……get my meaning? Do you understand now? Or need I explain it a LOT more?

  18. Linux Boxer Says:

    I need it wiped clean, so there IS NO PASSWORD!!!!! Hello?

  19. Another Someone! Says:

    For all those M$ supporters who think Windows is more secure:
    home.eunet.no/pnordahl/ntpasswd/

    A sweet, 60-second procedure.

  20. Milton Says:

    your process of system recovery did work for the password to be reset thanks very much

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>