Saturday, July 20, 2013

Grub Configuration File

GRUB has only a single config file, /boot/grub/grub.conf actually have soft links with /etc/grub.conf. When GRUB starts, it reads its configuration from the main config file. You can make changes on the command line to test different features of GRUB.
Now let’s look at the new version of the grub.conf file for RHEL6:
# cat grub.conf
default=0
timeout=5
splashimage=(hd0,0)/grub/splash.xpm.gz
hiddenmenu
title Red Hat Enterprise Linux (2.6.32-71.el6.x86_64)
root (hd0,0)
kernel /vmlinuz-2.6.32-71.el6.x86_64 ro root=/dev/mapper/vg_rhel01-lv_root
rd_LVM_LV=vg_rhel01/lv_root rd_LVM_LV=vg_rhel01/lv_swap rd_NO_LUKS rd_NO_MD
rd_NO_DM LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 KEYBOARDTYPE=pc
KEYTABLE=us crashkernel=auto rhgb quiet
initrd /initramfs-2.6.32-71.el6.x86_64.img

Now let's have a look the meaning of these options
default=0 means default kernel will load that is Linux, 1 means i want to load other OS or kernel if  installed
timeout=5 means you have 5 sec. to select manual options. if you want to modify kernel before booting you need to interrupt booting within 5 seconds.
splashimage= location of file that will use during booting.
title= display name of Kernel or O.S.
root(hd0,0)= where is boot partition is located in my case partition 0 on disk 0.
kernel = used kernel parameters like as encryption, RAID, LVM, language etc. Don't change any grub options until you don't know exact meaning of that otherwise you might be unable to boot system if you misconfigure any option.
Now use any file editor to modify options and reboot your system to see results. If there is any problem write to us on comment box we will try to help you.

No comments:

Post a Comment