Posted by Admin on Friday, November 18, 2016
In this Artical we are going to learn how to recover forgotten root password.
As a Linux Administrator some time we face challenges when some how we forgot the root password and without root access we can't do any kind of administrative task's in Linux.But luckily there is a easy way to recover the forgotten password.
So let's have look at the step's to recover the root password.
STEP 1 >>
Restart the system and press any key to interrupt the normal boot process to use the menu before it enters in to the Operating System.
After interrupt the normal boot process system will allow us to use the menu to
edit the grub so that we can recover the root password.
As we can see the system is allowing us to edit the menu by press "e".
So press "e" to go toward next step.
Note :- If you have protected your GRUB by password then it will ask to press "p" to enter the password to unlock the GRUB and then it will allow to edit the menu by pressing "e".
STEP 2 >>
Note :- If you have protected your GRUB by password then it will ask to press "p" to enter the password to unlock the GRUB and then it will allow to edit the menu by pressing "e".
STEP 2 >>
After the main menu now we moved to a new page where we have to edit the kernel argument by pressing "e", As we can see in the snapshot above the Kernel argument is there on second line.
Note : -We can move the cursor by UP and Down arrow on the keyboard.
So select the second line as selected above on the snapshot and press "e" to edit the kernel argument.
After make changes the line would look like this as shown in the snapshot above.
Now as shown on the snapshot above select the kernel line and press "b" to boot Operating System in a Single User Mode.
Now it will take to the shell prompt.
STEP 4 >>
At shell prompt just type below command to reset the password.
$ passwd root # To
reset the root password
Output :
No comments:
Post a Comment