RECOVERING YOUR LINUX DISTRO

Actually ive made the same post at blogspot but want to shift to wordpress so posting here…Many ppl out there are wondering if we can get back our linux installation after installling windows.this post is completely dedicated to it.To start of with windows uses the ntldr for activating the initial boot and linux uses grub….grub is more powerful than ntldr as we can
include a total of 26 o.s as far as i knw…..
our assumptions are that we had installed our grub on MBR,and u have a live cd wid u.
now when u install Xp after installing Linux ur grub gets overwritten with the ntldr and we have to get back our grub to dual boot.

Step 1:boot the live-cd and open the terminal

Step 2:fire up with the command sudo grub

step 3:If you are not sure which partition actually holds these files, use the command “find /boot/grub/stage1
it will return something lyk (hd0,5)as in my case….

Step 4: Now, set the GRUB’s root device to the boot directory, like this:                       issue command “root (hd0,5)”
Note:remember there is a space btw root and (hd0,5)

Step 5:Once you’ve set the root device correctly,its time to setup grub now with the command “setup (hd0)”

if everything is done as said above then ur done with…….just reboot ur computer and edit ur grub conf file for any changes req…..

7 Replies to “RECOVERING YOUR LINUX DISTRO”

  1. When I type the command
    find /boot/grub/stage1
    there is an error like “Not found”, dont remember exactly, coz am on windows now figuring out what to do next

  2. It means that u’ve lost ur stage1 file.Btw which distro is installed coz the command depends on ur distro either ‘find /boot/stage1’ or ‘find /stage1’ says u boot stuff result n also there are grub crashing issues with 7.10 and do u see ny post messages on screen while booting if then can u post them……n y do want reinstall grub and did u issue the command at grub prompt or terminal?

  3. I had edgy and everything was working perfectly, then i installed windows.
    Then I booted throught the live CD, went to terminal, typed sudo grub and in grub prompt typed find /boot/grub/stage1 , got the error like “Device not Found” or “File Does not exist”.
    Do I have to chroot into the live enviroment.

  4. yeah u r right (sudo mkdir ubuntu) mount the root (/) partition of ubuntu (e.g. sudo mount -t ext3 /dev/hda0 ubuntu and chroot the mounted partition (chroot ubuntu) and grub-install /dev/hda [1]

    Btw is this is a surprise test for me???????..or Flaming….huh….

    N also check ur motherboard whether it is a old one coz old mobo’s searches for its MBR within the first 8gb of space on the HDD and if ur windows install exceeds 8gb the motherboard could not find it…..lolololzzzzzzz…….

  5. I had heard about the chroot but didnt know how it happened… Thanks for the info. But one more problem, in grub-install /dev/sda it gives error like
    “Not a Block Device”

    And it isnt a test for you. I too write HOWTO’s for Linux, but this rescuing linux is the thing which has kept me banging my head for long.

    And mine is a new motherboard. Bought the laptop on August,2006. Hope that problem you mentioned is not faced here.

Leave a Reply

Your email address will not be published. Required fields are marked *