Linux single user mode password reset

 

Hello all,

 

This post helps you in resetting your Linux root password, if you forgot it. Before we get started we want to make sure that we either have a console or direct access to the machine to accomplish this task.

 

1. Reboot your machine and wait for the below prompt.

1

 

2. Press any key and then you will be taken to the below menu.

screenshot 1

 

3. Press key ‘e’ to edit the line as described in the lines of the above screenshot.

2

 

4. choose the desired kernel and  press ‘e’ again to edit the line and type single at the end of the line as shown below and press enter.

3

 

5. Now, you will see the below prompt then press ‘b’ key to boot the machine.

4

 

6. The machine will boot and enter into the single user mode as given in the screenshot below. Now, you can reset the password as mentioned in the below two screenshots.

5

6

 



Finally, you are done. Reboot the machine and take the control over. 🙂

Leave a Reply

Protected by WP Anti Spam