Linux Microsoft VMware
Showing posts with label Troubleshooting. Show all posts
Showing posts with label Troubleshooting. Show all posts

Tuesday, August 28, 2012

Rescue Linux Installation in RHEL / CENTOS / Fedora


Rescuing a Linux system is an easier task. There are several aspects of rescuing a Linux system.
Here we are going to see how to rescue an installed Linux system when the GRUB is deleted.
Suppose you are having a Linux system. Recently you installed a Windows OS into a new partition unchanging the Linux partitions. Once after you have installed Windows, the Linux no longer boots. This is because the windows install will overwrite the MBR thereby deleting / removing the GRUB boot loader.
In this case you are having the Linux partitions. Only thing is that it is not booting. Fixing this problem is very simple. Just install GRUB. That’s all to do.

Step 1: Boot from the install CD / DVD (net-install also)
Step 2
: Select the “Rescue Installed System” in GUI


Or type in “linux rescue” command in the “boot:


Now the system is booting the rescue image. Choose your language.

Select Keyboard type

The networking setup. We dont want the networking interfaces during the rescue process. So prefer opt the “No” option to not start the networking interfaces.

This step will now attempt to find your Linux installation and mount it under the directory /mnt/sysimage. So to continue select “Continue“.

Searching
10-> 20-> 30-> 40-> 50-> 60-> 70-> 80-> 90-> 100

If the rescue environment was unable to find your Linux installation you will be getting a message like this.
And if the rescue environment was able to find the Linux installation, it will get mounted under the /mnt/sysimage directory.



Now Supply the following commands
sh-3.2# chroot /mnt/sysimage
sh-3.2# grub-install /dev/sda
Installation finished. No error reported.
This is the contents of the device map /boot/grub/device.map.
Check if this is correct or not. If any of the lines is incorrect,
fix it and re-run the script 'grub-install'.
 
# this device map was generated by anaconda
(hd0)     /dev/sda
/dev/sda is the name of you hdd. check it carefully.

Now reboot.

sh-3.2# reboot

Or

init 6 to reboot.
Now see your Linux OS in the OS chooser menu.









Powered by Blogger.