[Mageia-dev] Grub2 vs. Grub Legacy in M3

Barry Jackson zen25000 at zen.co.uk
Sun Jan 27 13:31:37 CET 2013


On 20/01/13 17:42, Maurice Batey wrote:
> On Sun, 20 Jan 2013 14:50:06 +0000, Barry Jackson wrote:
>
>>   I repeat - "Installing the grub2 package"
>
>    OK - so you differentiate between "installing with GRUB2" and
> "installing the GRUB2 packge?
>
I am differentiating between "# urpmi grub2" and the use of the 
"grub2-install" command.
>    Does the former include the latter?
> Or do you mean one can install with GRUB Legacy and then go on to
> install the GRUB2 *package* (which presumably doesn't do anything but
> make itself available for the purposes you described)?
>
Exactly, except that it does create a menu and builds it's kernel 
(core.img) which it places in the /boot/grub2 directory ready for use.
It does no more than this and does not affect the existing MBR or PBR in 
any way.

>> This automatically creates core.img in /boot/grub2/i386-pc/ which
>> allows
>> you to boot into it from either grub2 using the multiboot command or from
>> legacy, using the menu entry shown in the readme.
>
>     What/where is the 'multiboot command'?

multiboot is a grub2 command to boot using core.img directly.
Below is my entry for Mga3 in my "master" grub2 grub.cfg which is in a 
small grub partition at the start of sda. My MBR points to this 
partition, so all OS's are either chainloaded or multibooted from the 
manually created entries in this grub.cfg

menuentry 'Mageia-3' {
search --no-floppy --label --set=root mageia-3
multiboot /boot/grub2/i386-pc/core.img

My limited understanding is that it is similar to chainloading but does 
not need embedded code in the PBR. Since grub2 can read the filesystem 
(with the appropriate modules loaded) it can navigate to the location of 
core.img and launch it.
A useful side effect is that grub legacy may be installed to the PBR and 
used if required, using:-

menuentry 'Mageia-3 {
search --no-floppy --label --set=root mageia-3
chainloader +1
}

>> Did you test it in Mageia as described in the README.Mageia ?
>
>      The GRUB2 I tried was from Ubuntu 12.01 and Mint 13, not Mageia.
>
>> If you add Mageia (grub2) entry to menu.lst as described and boot into
>> the Grub2 menu it will have all your legacy systems listed. Do they
>> not boot? .
>
>    Good question. The "GRUB2-to-Grub Legacy' boots I attempted via GRUB2
> in the MBR all failed.
>     Next time I get the netbook out I will try booting a GRUB Legacy
> install via a GRUB Legacy boot menu entry for booting a GRUB2 install.
> (Remember, it has GRUB Legacy in the MBR.)

Yes that's fine
>
> But I expect the result to be the same as booting GRUB legacy from
> GRUB2 in the MBR.
>
:\

> If the failure to boot  was caused by a faulty GRUB2 component, as has
> been suggested, then the test will have to await my installing Mageia-3
> with GRUB2, which may not happen very soon.
>

Have fun ;)

Barry


More information about the Mageia-dev mailing list