Announcement

Collapse
No announcement yet.

bootloader, grub, MBR assistance needed

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    bootloader, grub, MBR assistance needed

    I have a few versions of windows dual booted with kubuntu 9.04. Everything was working just peachy until windows xp crapped out, and I reinstalled it. Now it automatically loads windows xp without regard to any other operating system. So I went in to try to fix the issue and this is where I run into problems:

    grub> geometry (hd0)
    Error 21: Selected disk does not exist
    grub> geometry (hd0,0)
    Error 21: Selected disk does not exist
    ...
    grub> find /boot/grub/stage1
    Error 15: File not found

    and so on no matter what I enter. I have two hard drives, both are sata. I can load kubuntu using a Super Grub disk, and it usually starts windows xp.... but how do I recover my MBR?

    #2
    Re: bootloader, grub, MBR assistance needed

    Use SGD to boot into your Kubuntu. Look there and see if you can see /boot/grub/stage1.
    Then try again sudo grub and geometry and root-setup-quit.

    Otherwise, boot into SGD and choose GNU/Linux > Fix boot.
    An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

    Comment


      #3
      Re: bootloader, grub, MBR assistance needed

      Hello,
      I have a similar problem in fact so I thought I'd crash this topic.. Hope it's ok.

      I have 3 hard drives.

      I had WIN xp installed, then I installed Windows 7. When PC starts - I get the WIN 7 boot loader asking me to choose between XP and 7.

      Then I installed Kubuntu. Installation went fine but when the PC restarted - I got the Win7 boot loader only (no Kubuntu on it).

      So I assumed that grub got installed on another HDD.

      When I tried using SGD to fix the grub/mbr - I get an error:

      "find f /grub/stage1 /boot/grub/stage1
      Error 15: File not found "

      Does this mean that grub did not install at all?

      I also tried to load Kubuntu using the SGD but I got an error:

      "Error 13: Invalid or unsupported executable format"

      Any idea if I can fix that without re-installing Kubuntu?

      It's my first time trying Kubuntu. In the past I managed to have a dual/triple boot with Ubuntu so I'm not sure why it didn't work now But I'm still new to Linux world, so I'd appreciate any help! Thanks

      -----

      edit - I did reinstall Kubuntu once again on the first partition, grub installed just fine this time. so for now I'm all set. almost.

      Comment


        #4
        Re: bootloader, grub, MBR assistance needed

        Yes, you can fix it.

        You might try SGD again, poking around its various options to see if it will go right. Sounds like SGD had trouble identifying the disk correctly.

        You might try the method in this link:
        Vista *** The definitive dual-booting guide: Linux, Vista, 7 and XP step-by-step
        http://apcmag.com/dualboot


        You can also do it manually, with some effort.
        The details are all here:

        -- How To GRUB Methods - Toolkit
        http://kubuntuforums.net/forums/inde...opic=3081671.0

        Here's an outline of what you need to do:

        You must do most of this work as root.
        Use SGD to boot into Kubuntu IF you can, and then do all this wok in Kubuntu using Konsole.
        Otherwise, you can do all this work from a Live Kubuntu CD (the how-to tells how).

        You have to build a /boot/grub directory (with the GRUB files in it).
        Then re-install GRUB using those files.
        Then build a boot menu, /boot/grub/menu.lst.

        It sounds like you may not have /boot/grub directory or the files that should be there, so build that first.
        In /boot directory (of Kubuntu), create a subdirectory /grub, thus /boot/grub.
        Copy GRUB files into /boot/grub from /usr/lib/grub/i386-pc. COPY, do not MOVE!
        Now, you have /boot/grub in Kubuntu built.

        Use those files to re-install GRUB from Kubuntu partition to the MBR of the first BIOS boot drive.
        So you must explore your drives to find out which drive contains what.
        For that, use the GRUB geometry command (see how-to).
        Then you reinstall GRUB from the GRUB files in Kubuntu to the MBR of the first BIOS boot drive:
        grub>root (hdx,y)
        grub>setup (hdz)
        grub>setup (hdx,y)
        grub>quit

        where (hdx,y) is the Kubuntu partition and (hdz) is the first BIOS boot drive (which may be (hd0)).

        Then reboot to test it. If you do not have a boot menu (/boot/grub/menu.lst), you will be dropped to the GRUB prompt upon rebooting:
        grub>
        So use that to boot into your Kubuntu:
        grub>chainloader (hdx,y)
        grub>boot

        where (hdx,y) is your Kubuntu partition.
        After booting into Kubuntu, build a boot menu, /boot/grub/menu.lst.

        At Konsole, you can TRY to build menu.lst using
        sudo upgate-grub
        and see if that works. Otherwise, try to built one manually, like this:

        default 0
        timeout 10

        title Kubuntu on (hdx,y)
        root (hdx,y)
        chainloader +1

        title Windows Vista on (hdc,d)
        rootnoverify (hdc,d)
        chainloader +1

        title Windows 7 on (hda,b)
        rootnoverify (hda,b)
        chainloader +1
        An intellectual says a simple thing in a hard way. An artist says a hard thing in a simple way. Charles Bukowski

        Comment

        Working...
        X