Grub Password

1)grub password
1@@@@generate the passwd char.
[root@station78 ~]# grub
Probing devices to guess BIOS drives. This may take a long time.
Unknown partition table signature
    GNU GRUB  version 0.97  (640K lower / 3072K upper memory)
 [ Minimal BASH-like line editing is supported.  For the first word, TAB
   lists possible command completions.  Anywhere else TAB lists the possible
   completions of a device/filename.]
grub> md5crypt
md5crypt
Password: oracle
oracle
Encrypted: $1$DiC8q0$KKP818cz4uKHXd5AFAMXB/
grub> quit
quit

2@@@@edit grub.conf
[root@station78 ~]# cat /etc/grub.conf
# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE:  You have a /boot partition.  This means that
#          all kernel and initrd paths are relative to /boot/, eg.
#          root (hd0,2)
#          kernel /vmlinuz-version ro root=/dev/mapper/vg-root
#          initrd /initrd-[generic-]version.img
#boot=/dev/sda
default=0
timeout=10
splashimage=(hd0,2)/grub/splash.xpm.gz
hiddenmenu
title Red Hat Enterprise Linux (2.6.32-220.el6.x86_64)
    root (hd0,2)
    kernel /vmlinuz-2.6.32-220.el6.x86_64 ro root=/dev/mapper/vg-root rd_NO_LUKS  KEYBOARDTYPE=pc KEYTABLE=us LANG=en_US.UTF-8 rd_NO_MD quiet rd_LVM_LV=vg/swap SYSFONT=latarcyrheb-sun16 rhgb crashkernel=128M rd_LVM_LV=vg/root rd_NO_DM
    initrd /initramfs-2.6.32-220.el6.x86_64.img
title Windows 7
    rootnoverify (hd0,0)
    chainloader +1
title Rescue Hard Device
      root (hd0,2)
      kernel /isolinux/vmlinux rescue
      initrd /isolinux/initrd.img
title Test Grub Password
lock
password --md5 $1$DiC8q0$KKP818cz4uKHXd5AFAMXB/
      root (hd0,2)
      kernel /vmlinuz-2.6.32-220.el6.x86_64 ro root=/dev/mapper/vg-root rd_NO_LUKS  KEYBOARDTYPE=pc KEYTABLE=us LANG=en_US.UTF-8 rd_NO_MD quiet rd_LVM_LV=vg/swap SYSFONT=latarcyrheb-sun16 rhgb crashkernel=128M rd_LVM_LV=vg/root rd_NO_DM
      initrd /initramfs-2.6.32-220.el6.x86_64.img

你可能感兴趣的:(password,grub,RHEL6)