From Mageia wiki
Jump to: navigation, search


Use Grub 2 as default for Mageia 3.

Installation of grub2 does not change the default Grub Legacy bootloader in any way and may be installed alongside it. There is a README.Mageia in the package which explains it's basic use, and how to add grub2 to a grub legacy menu for testing.


  • Name:
  • Email:


  • Grub 2 packager: barjac
  • Installer developer: tv / tmb
  • drakxtools developer: tv
  • dracut packager: colin
  • kernel packager: tmb
  • gfxboot packager: nobody

Current status

  • Targeted release: Mageia 3
  • Last updated: 2021/01/25
  • Percentage of completion: 95%

One major bug still affects installation from any live iso. Workaround would be to install with grub and install grub2 after first boot.

Grub2 can now be selected during classic installer and may be installed to the MBR or, if a partition is selected then grub2's core.img (kernel) is written to /boot/grub2/i386-pc/core.img. This allows for multi-booting from either grub legacy or grub2. (see /usr/share/doc/grub2/README.Mageia. For chainloading it is possible to force the install to a partition boot sector with: grub2-install --force /dev/sdxy which uses blocklists, however this is NOT recommended.

Grub2 is now integrated into drakboot and the bootloader may be changed using this utility, however the menu cannot yet be customized from drakboot. There is a standalone utility in the repositories (grub-customizer), which may be used if it is felt necessary to modify the grub2 menu manually. Alternatively there are native grub2 options for manually adding to the menus. (see /usr/share/doc/grub2/README.Mageia)

Tracker bug

Detailed Description

Grub 2 as default needs to have changes in various areas:

  • installer
  • drakxtools
  • scripts that add new kernel entry

Grub 2 package in Cauldron already does this with filetriggers and os-prober.

  • scripts that detect other distros/pre-existing grub installation

Already integrated in Grub 2 when os-prober is available. The package in Cauldron suggests os-prober.

  • gfxboot?

Grub 2 handles themes - this Mageia theme is default in the Cauldron package using a custom MageiaLogo font thanks to diogenese. Note that the theme may be easily removed in minimal installations by uninstalling it. (urpme grub2-mageia-theme) No other action is needed.

Grub2 mga3.png

Why it would be good for Mageia to include it

  • Grub Legacy has not been maintained upstream for several years
  • better integration with newer technologies like btrfs
  • better detection of other distros
  • support EFI-based hardware (many recent laptops, both Mac and PC). There is no support at all in mga 2, since it does not include the EFI-aware version of grub-legacy (present e.g. in Fedora)

Test case

  • First boot after installing should work

This does work in all testing so far except for a current issue with the LIVE isos

  • changing entries via MCC should work

This is not yet implemented and is mentioned in errata.

  • detection of other distributions after an install on multi-boot systems

This works correctly with the default installation which includes os-prober. It is possible to uninstall or disable os-prober (see README.Mageia) in multi-boot environments where a master bootloader is used, to restrict the Mageia menu to not show all other operating systems.

  • ISO testing: livemedia/installations

Currently (Saturday 27 Apr 2013) grub2 installation from any LIVE iso fails, this is being worked on.

  • booting with a btrfs as / and single partition

Tests needed.

  • testing with and without separate /boot partition

Works for me.

  • test with gfxboot

Seems fine.

  • speed test (see fedora bug)

I have seen no adverse reports in Mageia testing.

Software / Packages Dependencies

  • grub2
  • os-prober
  • kernel
  • dracut
  • drakxtools
  • installer

What could disrupt development of this new feature

  • proper drakxtools integration
  • gfxboot
  • UEFI issues to be considered


should be completed before alpha1


  • set Grub Legacy back as default
  • revert possible gfxboot adjustments
  • revert changes in drakxtools
  • revert changes in installer scripts

Release Notes

When installing GRUB 2 to a partition (for multi-booting) using drakboot or the installer, nothing is written to the partition boot sector as this is not recommended for reliability reasons related to the use of block lists. These are prone to overwriting by some file system utilities, and not even possible on some file systems. Instead a copy of the grub2 kernel is written as /boot/grub2/i386-pc/core.img and this may be booted from either grub or grub2 used in a dedicated master bootloader or in another system. Note that since the PBR is not used by grub2 it may be used by grub while both are installed together, allowing for chainloading into grub and multibooting into grub2 from two master menu entries.

When a minimal install of grub2 is needed it may be installed with --no-suggests which will omit os-prober and the grub2-mageia-theme, giving a classic grub2 text only menu with no other systems listed. os-prober may be installed later and will list other systems automatically at the next boot. Likewise with the grub2-mageia-theme package - just install it and it will be shown at the next boot.


The full Grub (meaning Grub 2) documentation is available here