@gohlip: would such a boot configuration be a potential problem?
A bios-legacy boot (at bios) most likely will not detect a (correct) gpt disk, and hence cannot boot it. [1]
I'm already surprised his mbr from sda can boot OS from his (incorrect) gpt disk (perhaps this 'mbr protective helps, ironically).
A uefi system does not require mbr from sda to boot.
Though it must has an $esp partition mounted as /boot/efi [2] that in
rough comparison, acts as the 'mbr' and therefore grub does not need to specify sda (or sdb) in grub commands or in installation [3].
Some notes to clarify or make accurate.
[1] a uefi boot can usually detect an msdos disk and can boot OS from a msdos disk
but always good not to mix gpt and msdos and not mix uefi and bios-legacy boots.
Can be done but inadvisable.
Though bios-legacy can boot a gpt disk (through bios-grub and flagged and....),
as a rule, with msdos disk boot bios-legacy and with gpt, boot uefi.
Less hassles and headaches (2 TB notwithstanding).
[2] The $esp (fat32 format) for grub 2 requires mount point as /boot/efi
though when using rEFInd, it can be /boot (can also be /boot/efi)
and when using bootctl (systemd boot), it must be /boot only.
[3] a grub command for bios-legacy is like
- Code: Select all
# grub-install /dev/sda
without specifying '/dev/sda' it will fail.
A grub command for uefi
- Code: Select all
# grub-install
will work without specifying '/dev/sda' though it (now) works with specifying '/dev/sda' so as not to confuse people coming from bios-legacy; this '/dev/sda' will be ignored if specified. It is really unnecessary.
A more detailed grub-command (usually to fix grub issues) is
- Code: Select all
# grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=mageia --boot-directory=/boot --recheck --debug
again note '/dev/sda' is not specified.
Also linux installers for uefi do not require device to be specified for bootloader location as like 'install bootloader in - sda/sdb/.../partition' but must specify mount point /boot/efi else installation will fail.
Phew... needs so many clarification to get things.... correct.
Hope all is clear, but if I made some errors, appreciate correction.
Cheers.
Why do we live? To prove not everything in nature has a purpose.