Linux Password Reset

You can reset a forgotten Linux password by using the following steps:

  1. When you start up your computer the GRUB menu should appear, but if it isn’t normally displayed you can make it appear by holding down one of the ‘Shift’ keys while the computer starts.
  2. Press the ‘e’ key to edit the start-up command sequence.
  3. Use the arrow keys to highlight the command line that begins with the word ‘kernel’.
  4. Use the right-arrow key, or the ‘End’ key, to move the cursor to the end of the line.
  5. Replace the part at the end of the command line with ‘rw init=/bin/bash’.
  6. Press ‘F10’ or ‘Ctrl + X’ to start up the computer using the modified command sequence.
  7. Once the computer has started up, you will be presented with a command prompt that has ‘root’ privileges.
  8. Type ‘passwd userName’ to set a new password for the specified account.
  9. Enter the new password.
  10. Restart the system normally.