Find the answer to your Linux question:
Results 1 to 9 of 9
I've spent 2 solid days on this now, searching, scouring, ect. I can't quite find exactly what I need . Bear with me....it's kind of long. I had WinXP and ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Sep 2007
    Posts
    7

    Unhappy GRUB error 5; Ubuntu replacing Suse with Win dual boot


    I've spent 2 solid days on this now, searching, scouring, ect. I can't quite find exactly what I need . Bear with me....it's kind of long.

    I had WinXP and Suse 10.2 as a successful dual boot setup. Windows on drive 1, and Suse on drive 2. For various reasons, I decided to replace Suse with Ubuntu.

    Ubuntu FF (Alternate CD) seemed to install fine, but upon reboot I got the GRUB error 5 and system halt. After searching a bit, I found the recommendations for SGD.

    I tried every appropriate option in SGD, including advanced options, and the only repair I was able to make was to restore the Windows MBR.

    EDIT: I should add that I have been unable to boot Linux directly with SGD.

    There were 3 main errors that I got depending on which option I chose:

    1) Error 15: /grub/stage1 and /boot/stage1 -- file does not exist (But they do, because I've checked them with Explore2fs from Windows

    2) Error 17: file system not recoginized (IIRC, I got this when trying to boot the hda MBR at some point.......probably before I restored it)

    3) Another error was that it couldn't find the 'conf' and 'menu.lst' files. SGD offered 4 default locations to check, and none of the worked, but yet Explore2fs clearly shows that they are there.

    When I installed Fawn, I started with the guided installer, but then switched to manual because I wanted better control of it......it seemed straight forward enough, but maybe I fouled up something.

    Ftr, the linux partition sizes: Swap= @800Mb, Ext3=@145Gb, /Boot=@2.5Gb

    I distinctly recall that the Ubuntu partitioner displayed the /boot partition as #7 in the list. Is that a possible problem right there? Are there any restrictions on the partition count?

    Explore2fs from Windows lists two partitions: hdb3, which contains a 'lost and found' directory, nothing more, AND hdb6, which is obviously the main Linux partition.

    Now, I installed the demo of '7tools partition manager'. Here's what it shows for drive #2:

    Part # Type

    1 Primary NTFS ....
    2 Primary Linux Swap2 761Mb
    3 Primary Linux Ext3 137Gb
    4 Extended ....
    5 Logical Linux Ext3 2.2Gb
    6 Logical NTFS ....
    7 Logical NTFS .....

    So, it appears that my boot partition is logical instead of primary. But GRUB can still boot from logicals, right?

    And there's the fact that the listing above shows the boot partition as #5, but when I installed Ubuntu, the partition manager showed it as #7. Perhaps the manager's listing was inaccurate?

    ...... I just booted with SGD again, and tinkered with some grub commands that I found online.....with disappointing results.

    The 'find' /vmlinuz ; /boot/linuz ; and /sbin/init, finds exactly zilch, but again, Explore2fs shows that they do exist. For some reason, GRUB is unable to properly search the partitions created.

    I did get the root command to work on one of the partitions, (hd1,3), I think, but the setup command after that yielded an error.


    ------------------------------ HERE'S MY MENU.LST FILE

    title Ubuntu, kernel 2.6.20-15-generic
    root (hd1,6)
    kernel /boot/vmlinuz-2.6.20-15-generic root=UUID=24154d0f-2e5c-478b-a0f2-5e20a718c08d ro quiet splash grub
    initrd /boot/initrd.img-2.6.20-15-generic
    quiet
    savedefault

    title Ubuntu, kernel 2.6.20-15-generic (recovery mode)
    root (hd1,6)
    kernel /boot/vmlinuz-2.6.20-15-generic root=UUID=24154d0f-2e5c-478b-a0f2-5e20a718c08d ro single
    initrd /boot/initrd.img-2.6.20-15-generic

    title Ubuntu, memtest86+
    root (hd1,6)
    kernel /boot/memtest86+.bin
    quiet

    ### END DEBIAN AUTOMAGIC KERNELS LIST

    # This is a divider, added to separate the menu items below from the Debian
    # ones.
    title Other operating systems:
    root


    # This entry automatically added by the Debian installer for a non-linux OS
    # on /dev/hda1
    title Microsoft Windows XP Home Edition
    root (hd0,0)
    savedefault
    makeactive
    chainloader +1


    I'm exhausted. I hope there's a solution for this.........besides reinstalling both OS's again. Thanks for any help.

  2. #2
    Super Moderator devils casper's Avatar
    Join Date
    Jun 2006
    Location
    Chandigarh, India
    Posts
    24,729
    Hi and Welcome !

    Boot up from any LiveCD and execute fdisk -l command. Post output here.
    It is amazing what you can accomplish if you do not care who gets the credit.
    New Users: Read This First

  3. #3
    Just Joined!
    Join Date
    Sep 2007
    Posts
    7
    Thanks for the response.

    fdisk -l : Yields nothing.

    I then tried fdisk - l /dev/hdb, and, /dev/hdb1,,,,,,7 for all partitions, and it simply responds, "cannot open /dev/hdb*"

    I opened file-browser and saw that the 2 linux partitions listed weren't mounted. Thought that might be it, but after mounting them, the fdisk commands produce the same result.

    Since the LiveCD is running, will these commands still automatically access the actual installed directories from the physical installation?

  4. $spacer_open
    $spacer_close
  5. #4
    Super Moderator devils casper's Avatar
    Join Date
    Jun 2006
    Location
    Chandigarh, India
    Posts
    24,729
    You must have root privileges to execute fdisk command. If you are using Ubuntu LiveCD then execute 'sudo fdisk -l'. Hit Enter key at Password prompt.
    Code:
    sudo fdisk -l
    In other LiveCDs, execute this
    Code:
    su -
    fdisk -l
    Quote Originally Posted by spaceboy
    Since the LiveCD is running, will these commands still automatically access the actual installed directories from the physical installation?
    One has to mount HD partitions to access data in most of LiveCDs
    It is amazing what you can accomplish if you do not care who gets the credit.
    New Users: Read This First

  6. #5
    Just Joined!
    Join Date
    Sep 2007
    Posts
    7
    Ok, here's the result:


    Disk /dev/hda: 40.0 GB, 40020664320 bytes
    255 heads, 63 sectors/track, 4865 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot Start End Blocks Id System
    /dev/hda1 * 1 4864 39070048+ 7 HPFS/NTFS

    Disk /dev/hdb: 500.1 GB, 500107862016 bytes
    255 heads, 63 sectors/track, 60801 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes

    Device Boot Start End Blocks Id System
    /dev/hdb1 1 1960 15735667 7 HPFS/NTFS
    /dev/hdb2 19982 60801 327886650 f W95 Ext'd (LBA)
    /dev/hdb3 1960 2057 779122 82 Linux swap / Solaris
    /dev/hdb4 2057 19981 143975697+ 83 Linux
    /dev/hdb5 20269 40536 162802678+ 7 HPFS/NTFS
    /dev/hdb6 40537 60801 162778581 7 HPFS/NTFS
    /dev/hdb7 * 19982 20268 2305264+ 83 Linux

    Partition table entries are not in disk order
    --------------------------

    Fdisk at least answers one question I had, that partition listings are not necessarily listed in physical order.

    As an experiment, I tried setting up my hdb as a boot drive:

    At the 'sudo grub' promt, I typed:

    root (hd1,6)
    setup (hd1)

    The root command responded with a blank line..... Is it supposed to actually give a confirmation message?

    And the setup command responded:

    Checking if "/boot/grub/stage1" exists... yes
    Checking if "/boot/grub/stage2" exists... yes
    Checking if "/boot/grub/e2fs_stage1_5" exists... yes
    Running "embed /boot/grub/e2fs_stage1_5 (hd1)"... 17 sectors are embedded.
    succeeded
    Running "install /boot/grub/stage1 (hd1) (hd1)1+17 p (hd1,6)/boot/grub/stage2
    /boot/grub/menu.lst"... succeeded
    Done.
    I then set the BIOS to boot the 2nd drive, but I still get grub error 5.

  7. #6
    Super Moderator devils casper's Avatar
    Join Date
    Jun 2006
    Location
    Chandigarh, India
    Posts
    24,729
    Its a GRUB/BIOS compatibility issue. Is it possible for you to plug-in Linux HD as Primary Master?
    It is amazing what you can accomplish if you do not care who gets the credit.
    New Users: Read This First

  8. #7
    Just Joined!
    Join Date
    Sep 2007
    Posts
    7
    Quote Originally Posted by devils_casper View Post
    Its a GRUB/BIOS compatibility issue. Is it possible for you to plug-in Linux HD as Primary Master?
    So you think this is the same problem in both cases? Are you referring to the 1024 sector problem with older BIOS's? My BIOS is only about 4-4 1/2 years old. I realize it's old in computer terms, but I thought that BIOS issue was with _really_ old chips!

    If that's the issue, then I can easily repartition and downsize the Linux partitions so that they come in under the required limit.........I'll have to look up a sector/size translation table for that unless you happen to know what it is.

    ....................but wait a second..........I had Suse on there before and GRUB worked fine. I did resize the partitions a small amount, IIRC. Maybe that was enough to push the /boot over the line? EDIT: Or........maybe the automated Suse installation placed the /boot before the 145Gb /root..........that sounds familiar..... With Ubuntu, I set it up manually and didn't figure that my BIOS would have that issue, and the /boot was setup last.

    Btw, is there a command I can use to see a partition listing of the physical order on disk?

  9. #8
    Super Moderator devils casper's Avatar
    Join Date
    Jun 2006
    Location
    Chandigarh, India
    Posts
    24,729
    It has nothing do with 1024 Cylinder Limit. A few BIOSes do not pass correct info to GRUB. In other words, if one installs GRUB in MBR of HD which dont have Linux installed, GRUB doesn't work in a few machines.
    Plug-in Linux HD as Primary Master and install GRUB in its MBR. Its very easy to add an entry of Windows OS ( installed in other HD ) in GRUB.
    It is amazing what you can accomplish if you do not care who gets the credit.
    New Users: Read This First

  10. #9
    Just Joined!
    Join Date
    Sep 2007
    Posts
    7
    I finally gave up and just repartitioned and reinstalled.

    Good enough. Thanks for your help!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •