How to re-install bootstrap code(GRUB)
If you repaired your system from backup tape by dump or tar, you need to repair the bootstrap area.
Re-install bootstrap code (GRUB)
Please do the following steps.
Step 1: Boot from CentOS installation disc (for example, CD #1 or DVD).
Step 2: Type "linux rescue" at the "boot:" prompt.
Step 3: Mount all filesystems in read-write mode.
Step 4: Change root to real root ('/') on your hard disk.
# chroot /mnt/sysimage
Step 5: Re-install bootstrap code (GRUB).
- If you re-install GRUB to MBR on SCSI disk or SATA disk (/dev/sda).
# grub-install /dev/sda
- If you re-install GRUB to PBR of Partition #2 on SCSI disk or SATA disk (/dev/sda2).
# grub-install /dev/sda2
- If you re-install GRUB to MBR on IDE disk (/dev/hda).
# grub-install /dev/hda
- If you re-install GRUB to MBR on HP Smart Array disk (/dev/c0d0).
# grub-install /dev/cciss/c0d0
