Reset forgotten root password on CentOS6.4

Posted: August 4, 2013 in Linux

Centos6.4

Reset forgotten root password on CentOS6.4

restart your computer

press any key to get grub menu

From the GRUB menu, select the appropriate kernel version and
press the ‘e’ key.
You will now be presented with the option menu for the kernel version.

From this menu, select the kernel /vmlinuz-… line and
press the ‘e’ key.
You will now be presented with the kernel boot options.

Now we need to add to the end of this line one o the following:
1, s, or single
And now press Enter to save your changes.

From this menu, you should already be on the kernel /vmlinuz… line.
Press the ‘b’ key to boot to these temporary options to allow you to recover your root account.

Now you will boot up to the root shell and you can use passwd to set your new password.

passwd root

and enter your new root password

and now change your mode to run level 5

init 5

========================================================================================

Advertisements
Comments

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s