Subscribe:

Ads 468x60px

Pages

Tuesday, May 24, 2011

Assigning and Recover Grub Password


Assigning Grub Password
# grub-md5-crypt
Password: (enter new password)
Retype password: (repeat password)
$1$s3YiK$M3lxAbqA6JLm2FbDWnClQ0

Copy the contents of grub-md5-crypt  in file tmpfile
# grub-md5-crypt > tmpfile

View the content of tmpfile
# cat tmpfile

Add the resulting hash value to the file /etc/grub.conf
# vi /etc/grub.conf

#hiddenmenu
password --md5 $1$s3YiK$M3lxAbqA6JLm2FbDWnClQ0
:wq

Reboot the system forcefully
#reboot –f


Removing Grub Password
*Boot the System in Rescue Mode
# chroot /mnt/sysimage

# vi /boot/grub/grub.conf
Remove line from /boot/grub/grub.conf
hidden menu
password — md5 <password>
title Red Hat ——

0 comments:

Post a Comment