LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Linux Red Hat9 with Grub, Problems with Multiple boot. (https://www.linuxquestions.org/questions/linux-newbie-8/linux-red-hat9-with-grub-problems-with-multiple-boot-155424/)

Momboking 03-09-2004 11:33 AM

Linux Red Hat9 with Grub, Problems with Multiple boot.
 
here is my grub.config:

default=0
timeout=10
splashimage=(hd0,5)/boot/grub/splash.xpm.gz
title Red Hat (2.4.20-8)
root (hd05)
kernel /boot/vmlinuz-2.4.20-8 ro root=LABES=/
initrd /boot/initrd-2.4.20-8.img
title DOS
rootnoverify (hd0,0)
chainloader +1
title Morphix
rootnoverify (hd0,4)
chainloader +1
------------------------------------------------------------------------------------------------

Ok, Windows and Linux RH9 works fine. My problem is with Morphix (Phlak).
I installed Morphix on the root of hd0,4, with lilo as the boot loader.

the error is "Error 13: Invalid or unsupported executable format"

Please help me be able to boot all three OS's from grub.

davemiles 03-11-2004 06:06 AM

I had this exact problem when trying to set up a multi-boot system with 2 x Fedora linux and FreeDOS.

Not sure if the underlying problem is actually a bug in grub, but its the same in Fedora Core 1 and in Redhat 9. You can work around this problem as follows for two linux systems ........

Here the second system was added after main system, main system is multi partition, second system is a single partition. During second install added config to grub to hopefully boot original system.

My config as follows:

Main System has /boot in /dev/hda4, root in /dev/hda5, others elsewhere
Second System is entirely in /dev/hda6

The second system boots ok, the original system can be selected from the menu, but the 'invalid or unsupported executable format' message appears.

The implication of this is the MBR on the root disk points to the new system.

Solution I used was to boot from diskette (you DO have a boot diskette for one of the systems I hope) to get the original system up. At the boot prompt 'boot: linux root=/dev/hda5'. Had a look at the original systems /boot/grub/menu.lst to find out exactly how it boots. Mounted the new systems root on a temporary mount point. Then modify the /boot/grub/menu.lst for the second system to point directly to the kernel

This is the resultant config file - note the paths to cope with the fact that on main system files are on a separate filesystem.

# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE: You do not have a /boot partition. This means that
# all kernel and initrd paths are relative to /, eg.
# root (hd0,6)
# kernel /boot/vmlinuz-version ro root=/dev/hda7
# initrd /boot/initrd-version.img
#boot=/dev/hda
default=1
timeout=10
splashimage=(hd0,6)/boot/grub/splash.xpm.gz
title Mini Fedora Core (2.4.22-1.2115.nptl)
root (hd0,6)
kernel /boot/vmlinuz-2.4.22-1.2115.nptl ro root=LABEL=/1 hdc=ide-scsi
initrd /boot/initrd-2.4.22-1.2115.nptl.img
title Main Fedora Core
root (hd0,4)
kernel /vmlinuz-2.4.22-1.2115.nptl ro root=LABEL=/ hdc=ide-scsi rhgb
initrd /initrd-2.4.22-1.2115.nptl.img
title DOS
rootnoverify (hd0,0)
chainloader +1

Hope this helps.

Demonbane 03-11-2004 06:58 AM

In order for chainloader a partition to work a boot loader has to to installed to the partition boot sector, you couldn''t boot your main system because it only had GRUB in the MBR. Yeah adding an entry to load the kernel from another partition will also work, GRUB is not "tied" to the distro you install it with.

davemiles 03-12-2004 03:40 PM

Hmmmm - maybe not so smart
 
Thanks, pretty dumb of me not to spot this myself. How long have I used Linux ? I prefer not to say. Have made a few changes and of course it works as expected. Sometimes just need to say these things out loud.

Regards


All times are GMT -5. The time now is 03:57 PM.