multiple distros on one harddrive - OpenSUSE usurped the bootloader
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
multiple distros on one harddrive - OpenSUSE usurped the bootloader
I partitioned my 2nd harddrive to host several distros. On the first harddrive I have Windows XP, the 2nd one has 3 OS-partitions, of which 1 currently empty, one with Bodhi Linux 1.3, and one with OpenSUSE 12.1 Lxde.
The latter one I installed last, and now the bootloader is Suse-styled and only gives me the choice between Win and Suse - I can't access Bodhi anymore.
I want to achieve
a) the bootloader giving me the choice to boot all OSes I have installed on both hdds
b) replacing Suse, probably with LinuxMint.
Is there some kind of step-by-step-guide on how to overwrite an existing distro? Where do I need to start?What are the things I need to be careful about?
If Opensuse is still using Grub Legacy as a bootloader, you would just need to create an entry for it the Opensuse menu.lst file. You would need to know the partition Bodhi is on. An entry such as the one below in the Opensuse menu.lst should work if Bodhi is on sda5.
You could also use a chainloader entry. As far as overwriting a distro, you would simply select the partition the old distro is on to install the new one (Mint) to.
How do I make sure which version of Grub it is?
I know which partition Bodhi is on (can see it in fstab, I think? Or blkid?), but how does that reflect in the line you posted to insert into Opensuse menu.lst?
What is a chainlaoder entry?
In Opensuse, go to the /boot/grub folder. If there is a menu.lst file, it is Grub Legacy.
The (hd0,4) indicates sda5, (hd0,3) would be sda4, etc...
A chainloader entry is pretty much the same as the above entry which also basically chainloads to the Bodhi boot menu. The example below is the equivalent of the previous core.img example. The zero in (hd0 refers to the first drive, the 4 in the entry refers to the 5th partition (sda5). Grub Legacy counts drives and partitions from zero while Grub2 (Bodhi) counts drives from zero and partitions from one.
Turns out if I open menu.lst as root, it's all there. Still it's weird that I don't get to at least see the file's content without a password...
So I changed it to look like this (last entry):
# Modified by YaST2. Last modification on Thu Feb 23 14:27:49 CET 2012
# THIS FILE WILL BE PARTIALLY OVERWRITTEN by perl-Bootloader
# For the new kernel it try to figure out old parameters. In case we are not able to recognize it (e.g. change of flavor or strange install order ) it it use as fallback installation parameters from /etc/sysconfig/bootloader
###Don't change this comment - YaST2 identifier: Original name: linux###
title Desktop -- openSUSE 12.1 - 3.1.9-1.4
kernel /boot/vmlinuz-3.1.9-1.4-desktop root=/dev/disk/by-id/ata-WDC_WD10EARS-00MVWB0_WD-WMAZA3871484-part3 resume=/dev/disk/by-id/ata-WDC_WD10EARS-00MVWB0_WD-WMAZA3871484-part6 splash=silent quiet showopts vga=0x348
###Don't change this comment - YaST2 identifier: Original name: failsafe###
title Failsafe -- openSUSE 12.1 - 3.1.9-1.4
kernel /boot/vmlinuz-3.1.9-1.4-desktop root=/dev/disk/by-id/ata-WDC_WD10EARS-00MVWB0_WD-WMAZA3871484-part3 showopts apm=off noresume edd=off powersaved=off nohz=off highres=off processor.max_cstate=1 nomodeset x11failsafe vga=0x348
###Don't change this comment - YaST2 identifier: Original name: Vendor diagnostic###
title Vendor diagnostic
###Don't change this comment - YaST2 identifier: Original name: windows###
###Don't change this comment - YaST2 identifier: Original name: Bodhi###
Bodhi is on the first partition of 2nd harddrive, and since Win (on 1st hdd) apparently is also loaded by chainloader, I tried this option first.
Bodhi now shows in Grub menu, but if I try and boot it, an error comes up and it goes back to menu.
GParted now has the first partition (with Bodhi) marked with some warning that the filesystem could not be properly read, and that might be due to a missing software package. It says that and e2fsprogs v 1.41+ is required for ext4 to work. That warning wasn't there before I modified menu.lst
, and I can now access Grub 2 and boot Bodhi again!
It's not yet the solution I want it to be though, because I have to go through 2 Grub menus to boot Bodhi.
I'd like all the options to be available in 1 menu that will always boot the selected OS directly.
That filesystem warning in Gparted is not there under Bodhi btw., but it's still there in GParted under SUSE and also appeared for the first partition of the Win hdd....?
Still it's weird that I don't get to at least see the file's content without a password...
Not really. It's intentional, by design. A user has no reason to look at it because s/he can't modify it so if you're having problems with Grub you would need to be root to do anything anyhow. Anyway, that's the way it is.
I'm not sure what the problem is with booting some systems from Grub Legacy but I have read that it is because Grub Legacy has problems booting anything on ext4 systems?? If you had two systems which both were using Grub2, you wouldn't have a problem with using just one Grub menu. I think the latest version of OPensuse now uses Grub2, haven't tried it so I'm not sure.
suppose I replace Suse with a different OS that uses "Grub 2", overwriting it, would that installation automatically write a new entry to the existing Grub2 menu, or would I have to specify that upfront/during installation? What would happen to Grub Legacy?
And on a side note, why do you refer to 1.xx versions of Grub (Bodhi uses 1.98) as "Grub 2"?
I'm not sure what the problem is with booting some systems from Grub Legacy but I have read that it is because Grub Legacy has problems booting anything on ext4 systems
Standard Grub1 ("Legacy" Grub can't handle ext4 because ext4 didn't exist at the time. However there are doctored versions (Ubuntu since at least Lucid) that can handle it.
Even bog standard Grub 1 can be used with an ext3 /boot partition which then boots the ext4 / partition. The /boot partition can be very small - 1Mb is ample.
I follow Saikee and have Grub1 on the MBR pointing to my "main" distro's menu.lst. All other distros have Grub1 installed to their "superblock" (first sector) and are booted by chainloading.
It is perfectly possible to do this with Grub2; it's just more complicated and there's no advantage. Grub 1 can chainload Grub2 and vice versa
You can copy a Ubuntu Grub1 to other distros - the only bits that really matter are the stage1 and stage2 files
If you make yourself a Grub boot CD (see Saikee) you can boot any Linux distro that isn't broken whether or not it has a boot loader, and other OSes if they have a boot loader.
suppose I replace Suse with a different OS that uses "Grub 2", overwriting it, would that installation automatically write a new entry to the existing Grub2 menu
What Grub2 menu? The information you have posted indicates you are booting your systems with the Opensuse bootloader which is Grub Legacy with menu.lst. If you install a new distribution which uses Grub2 (I think the most recent version of Opensuse now uses Grub2?), it should detect any other operating system on any attached drives and create entries for them in its grub.cfg file. If it doesn't, it is pretty easy to update Grub2.
During installation, you should have an option as to where to install the bootloader,the master boot record or any other partition. If you installed over the Opensuse partition Grub Legacy would be gone. If you installed to another partition, there would be no need for it but it would still be there.
why do you refer to 1.xx versions of Grub (Bodhi uses 1.98) as "Grub 2"?
Because the people who write Grub refer to it as such.
I mean the one that comes up when I choose Bodhi in the first GRub menu. The one that was installed by Bodhi.
If you install another system which uses Grub2 it will create its own configuration files including the /boot/grub/grub.cfg file. If you selected to install this systems Grub to the master boot record, it would boot the systems from a new menu. It would not change the Bodhi grub files and if you booted from the new systems Grub2, the Bodhi Grub files would not be used.
During installation, you should have an option as to where to install the bootloader,the master boot record or any other partition.
How would that choice be labelled? I recently installed Lubuntu on my laptop, adn for a choice there is a graph of my partitions, and I have to choose one for installation and name a mount point.
There isn't a choice explicitly labelled anyhting like "where do you want to put your bootloader?" or sth....