0

I have a pc with a HDD failure. After I replaced the HDD and installed the Acronis backup image on the new HDD , the unit is not booting . It`s showing "GRUB _ " and that is it .

I`ve tried to boot manually with YUMI live usb , but when I select CentOS I get the following errors : 'Error: could not load file/boot/vmlinuz-2.6.18-348.el5PAE ' 'Error: you need to load the kernel first .'

Files are on hd1,msdos1 according YUMI.

How can I fix the Grub in order to boot properly ?

1 Answer 1

0

It looks like some parts of your /boot directory may have been already damaged when the backup was taken. Do you have an older backup you could try restoring?

Alternatively, you could try booting the system to rescue mode from a CentOS 5.9 installation media: it will ask you to select the language and keyboard layout just like in the beginning of a regular installation, then switch into rescue mode: it will allow you to activate a network interface and then (hopefully) automatically mount your installed system to /mnt/sysimage. Then it will give you a root shell, with a suggestion that the command chroot /mnt/sysimage will allow you to access your installed system.

So use the suggested command, and then check the integrity of the kernel packages:

chroot /mnt/sysimage
rpm -V 'kernel-PAE*'

If the kernel package is OK, the rpm -V command will display nothing. If the kernel package is damaged, you might try to reinstall it with yum reinstall kernel-PAE or similar command.

If you haven't already configured this system to use the archive repositories at vault.centos.org, you might have to do that first. As the GPG keys of CentOS 5.x have probably expired by now, you might have to set gpgcheck=0 in the repository configuration for it to allow the packages to be installed.

To reinstall GRUB on your system disk, first run cat /boot/grub/device.map and verify it makes sense regarding your current system configuration (i.e. (hd0) is referring to the disk that will be your system disk when your system is running normally) and adjust if necessary, then run grub-install /dev/sda, replacing /dev/sda with your actual system disk device.

Then run exit twice: the first exit will undo the chroot /mnt/sysimage command, and the second will exit the rescue environment, which will trigger an automatic reboot.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .