September 25, 2007 · General, Security · Email This Post

Sponsored Link
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

Incoming search terms:

Related posts

86 Comments to “How-To Recover password under Ubuntu”

  1. Freak says:

    my ibook made a friggen liar out of me. put a panther disk in and it actually booted setup! ok. i guess, nevermind then *^_^*

    [Reply]

  2. Kraven says:

    I’ve done this, but I can’t seem to find the line that begins “kernel…”

    [Reply]

    steve Reply:

    i have the same, did you find the answer?

    [Reply]

  3. Flood says:

    If you have a user with sudo rights (by default in ubuntu, you first user will have this right)
    just type this:

    sudo passwd root

    cheers!

    [Reply]

  4. Mike says:

    Thanks! It worked!

    [Reply]

  5. hi ubuntu 10.10

    not able to hit escape on boot up. Can not get to root. I can log in as administrator. I can not get to root using sudo. It says there is a problem with the sudos file. This happened when i installed the latest ubuntu updates

    All I can do is switch it off and then on. The only option is to reload, ubuntu.

    [Reply]

  6. Basu says:

    I installed ubuntu 10.10 version to my Dell laptop..,by mistake i deleted existing username in user managemant and i added new user name and password in that place..,after rebooting it wont get login .., so i need it very urgently , i am worried .., please send me the procedure to recover the password …,

    [Reply]

  7. Basu says:

    I have ubuntu 10.10 to my Dell laptop.., i forgot username and password..,i tried from ubuntu live cd ., but i didnt get it ., so plase tell me how to recover the password..,

    [Reply]

  8. Basu says:

    ubuntu 10.10

    i am not able to hit escape on boot up. Can not get to root. I can log in as administrator. I can not get to root using sudo. It says there is a problem with the sudos file. i forgot usernsme and password so plase help me..,

    [Reply]

  9. fizzle says:

    mine won’t let me reboot any advice?

    [Reply]

  10. pawa says:

    We don’t have GRUB menu in Ubuntu 10.10!

    [Reply]

  11. mathias01234 says:

    I use Mint Linux (based on Ubuntu), but the above solution to get a root shell without password doesn’t work.

    The system restarts, I use the arrow keys to choose “recovery” and type “e”, well I can edit the kernel-line and add “init=/bin/bash” but if I press ENTER, a new line is added. If I press ESC all changes are gone and in the menu “b” has no effect.

    What’s the corret way to change the start up of current grup version?

    [Reply]

    n00b95 Reply:

    try pressing ctrl + x instead of enter

    [Reply]

  12. Rodney Beede says:

    For Ubuntu 10.10 Grub has been updated to Grub2.

    Hold down the shift key (I did left shift) instead of escape while booting up.

    [Reply]

  13. chris says:

    tnx. it works!

    [Reply]

  14. arun says:

    hi
    i shared my computer with my room mate and both of us had a separate administrative user account.He has removed my administrative rights.Can i get the password of his account.
    I have the root password

    [Reply]

  15. Terry Emery says:

    Witch line do I edit for password retival there are three that come up.

    ubuntu 8.04,kernal 2.6.24-16-generic

    ubuntu 8.04,kernal 2.6.24-16-generic [recovery mode]

    ubuntu 8.04 mentest86+

    [Reply]

  16. Enkouyami says:

    In Ubuntu 10.10 I went to very end of the line and added rw init=/bin/bash and now ubuntu seems to start up normally at first untill after the plymouth booting animation theres only a purple screen. When I logging through safe-mode theres a problem with the encryption manager. My home folder doesn’t get decrypted and because of that nautilus and gnome lack functionality.

    [Reply]

  17. corey says:

    this did not work for me says that root isn’t installed but in order to install anything i still need a password..when i try changing it using the passwd command says i still need a password to change it..followed the instructions to the T you gave above.

    [Reply]

  18. Dave says:

    Worked perfectly.. thx!!!

    [Reply]

  19. Kyle says:

    How do i get into recovery mode ??? Im on ubuntu 8.04 lts plzzzzz help

    [Reply]

  20. Kyle says:

    What is the grub prompt?

    [Reply]

  21. zeruel107 says:

    When i do this, passwd_space_user_space_password, I get to a “help desk”. It says : root@(none) :/# usage: passwd [options] [login]

    Options :
    And certain commands. I try to write my new password (not sure if its the timing to do it) and write reboot.
    I get the “error” saying shutdown: Unable to send message: connection refused.
    Can anyone help me from here? btw, 15 yrs old so this is pretty new. I have Vista (black screen of death before everything) so I try Ubuntu.

    [Reply]

  22. Erik says:

    What is the grub prompt?

    [Reply]

  23. xavier says:

    I do not have superuser password nor do I have root password, can someone please email me with any tip’s for begginer’s. It would be greatly appreciated thank you.

    [Reply]

Leave a Reply