Broken grub and getting only grub prompt at the startup

At this case you will get only a grub prompt while at the startup. Please follow the below steps to install grub.

grub> find /boot/grub/stage1

(This means the boot loader lies on the first harddisk hd0 and its 5th logical partition)

grub> root (hd0,5)

grub> kernel /boot/vmlinuz-2.6.18-238.19.1.el5.i386 ro root=/dev/sda6

(I gave /dev/sda6 because that is my “/” partition)

or you can as follows.

(check before that if label is already set or not to your root partition. For that boot in with the help of Live CD or be in rescue mode)
####bash-4.1# e2label /dev/sda6
#### /

(so confirmed label is there)

grub> kernel /boot/vmlinuz-2.6.18-238.19.1.el6.i386 ro root=LABEL=/

grub> initrd /boot/initrd-2.6.18-238.19.1.el6.i386.img

grub> boot

That’s it 🙂