Basically, I’ve integrated XFS filesystem support into my BIOS ROM by using UEFItool to add an FFS converted from the EFI driver provided by efifs. This allows my BIOS to directly boot grubx64.efi
from my XFS partition, and ultimately, boot my OS.
My primary motivation is to use Bcache for my root filesystem while avoiding the fragile FAT32 filesystem for both the ESP (EFI System Partition) and /boot
. However, under this setup, I can’t use grub-install --efi-directory=/boot
to install GRUB since this command doesn’t allow a non-FAT filesystem for the ESP.
Instead, I have to generate grubx64.efi
using the following command:
grub-mkimage -o /mnt/EFI/manjaro/grubx64.efi -p /boot/grub -O x86_64-efi -c grub_early.cfg \
normal part_gpt xfs search search_fs_uuid search_label
cat grub_early.cfg
search.fs_uuid 11111-11111-111111-111111-111111 root
set prefix=($root)/grub
Then, I need to obtain the essential GRUB modules from another source.
Afterward, I still have to use efibootmgr
to add the GRUB boot entry to the firmware.
In short, the GRUB installation process has become extremely complex. Is there any way to make grub-install
work correctly in this scenario?