Re: grub-install problem after trixie upgrade
Alain D D Williams composed on 2025-08-11 01:36 (UTC+0100):
> I have just upgraded from bookworm to trixie. An AMD FX (64 bit) machine.
> The main disk is 2 disks in a RAID-1 pair (mirroring). The boot partition is
> /dev/md0 that is built thus:
> md0 : active raid1 sda1[0] sdb1[1]
> 510976 blocks super 1.2 [2/2] [UU]
> I get an error installing grub. I do not understand it let alone know how to
> fix it. Note that the error happens for sda but not sdb:
> # grub-install --target=i386-pc /dev/sda
> Installing for i386-pc platform.
> grub-install: warning: You have a short MBR gap and use advanced config. Please increase post-MBR gap..
> grub-install: warning: your core.img is unusually large. It won't fit in the embedding area.
> grub-install: error: embedding is not possible, but this is required for RAID and LVM install.
> # grub-install --target=i386-pc /dev/sdb
> Installing for i386-pc platform.
> Installation finished. No error reported.
> My core.img:
> -rw-r--r-- 1 root root 33386 Aug 11 01:14 /boot/grub/i386-pc/core.img
> The disks are DOS partition table format not GUID as the hardware/BIOS does not
> understand GUID - I bought it in 2012.
GPT/UEFI booting predates 2012 by a number of years. Your BIOS could well
understand it if you desired to use it.
Is this a fresh installation, or an upgrade? Is the RAID freshly made, or an old
one reused without repartitioning?
In recent years, the maximum size MBR gap has commonly been 31 sectors, or 15872
bytes, so not enough to fit 33386 of core.img. In older MBR setups it was commonly
62, or 31744 bytes, still not enough.
My older RAIDs booted from still have Grub Legacy to boot from, and have Grub
installed on primary partitions, so gap size on them is of no importance. Also,
Those disk pairs each have multiple partitions making up multiple RAID1 devices,
but the boot partitions I don't bother to RAID. Instead I clone them to each
other, avoiding any issues with Grub upon RAID.
> There might be some clues here but I cannot reach it: https://lists.gnu.org/archive/html/grub-devel/2020-03/msg00134.html
> Can anyone offer any illumination ?
> Another problem is that it is 500 MB, trixie recommends that it should be 768
> MB; a problem that I shall worry about another day.
"It" what? A separate /boot/ filesystem? An ESP filesystem? 500 should be enough
for either, unless employing BLS[1] booting instead of Grub2 or other older
bootloaders. For BLS booting, other distros have been recommending 1G or more for
ESPs.
[1] https://uapi-group.org/specifications/specs/boot_loader_specification/
--
Evolution as taught in public schools is, like religion,
based on faith, not based on science.
Team OS/2 ** Reg. Linux User #211409 ** a11y rocks!
Felix Miata
Reply to: