Linux Programmer | RHCE | RHCSA

Search This Blog

Tuesday, 30 October 2018

Reset admin password ubuntu

How to reset administrative password in ubuntu

  1. start machine.
    After the BIOS screen appears, press down the left shift key to enter GRUB. This step can be quite finicky, and you may need to repeat it several times until you get the timing just right.
  2. Select the Advance Option for ubuntu
  3. .
  4. In Grub Version list, scroll down to the top Recovery mode line, and press Enter.
    If the Linux kernel image had been upgraded on the machine before, you would see multiple recover mode lines on the screen. Select the recovery mode line that corresponds to the latest Linux image(that is nearest to the top).
  5. In the Recovery Menu screen click on root 'Drop to root shell prompt'.
  6. Press Enter again.
    If you have set root a password, you would be prompted to enter it at this step. Otherwise, just press Enter to continue.
  7. Remount filesystem.
    After all the hard work, you are now at the root shell prompt. The filesystem at this point is read-only. Remount the file system to add write permission.
    $ mount -o rw,remount /
    
  8. Reset admin user password now.
    Use the passwd command to change the password for the admin user.
    $ passwd <username>
    
    Press Control-D to return to the recovery menu.
  9. Click on resume.
  10. Exit recovery.
    Press OK to exit recovery mode and continue booting.
Here you Go.

Password resetted successfully.

No comments:

Post a Comment

SSH not working with password after upgrade ubuntu 22.04 or above

In recent upgrade of ubuntu 22.04 and above we are not able to login server with SSH password. but when we try to login with key then it all...