Le 25/07/2017 à 16:03, Xen a ecrit :
Mistave schreef op 25-07-2017 14:19:

Unfortunately that doesn't work, and grub-install errors out with:
grub-install: warning: Attempting to install GRUB to a partitionless
disk or to a partition.  This is a BAD idea..
grub-install: error: embedding is not possible, but this is required
for RAID and LVM install.

I can't find any useful information about this error online. Why is
this happening, is the dedicated partition (1 meg) too small? Out of
curiosity I tried installing grub to MBR (/dev/sdb) directly, and it
installed fine with no errors (don't worry, I had a backup of the
first 2048 disk sectors which I dd'ed back to the HDD later on).

I'd love to know as well.

Unfortunately, grub-install does not allow to install the boot image and/or the core image in a raw unformatted partition. IMO it would be so useful, though.

The easiest way is to create a small filesystem in that partition, I think.

Not any type of filesystem, because /boot/grub is encrypted so embedding the core image is required, and you need a filesystem which supports embedding.

AFAIK, GRUB supports embedding with only two filesystems : XFS and btrfs. Some readings in GRUB changelogs suggested that it may support embedding with the Minix filesystem, but I could not manage to get it to work. Unfortunately, XFS and btrfs are not designed for partition as small as 1 MiB. The smallest size I managed to create a btrfs filesystem on was 5 MiB (with no available space for files).


Otherwise, leave /boot/grub unencrypted. But again, 1 MiB is too small for /boot/grub contents.

_______________________________________________
Help-grub mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/help-grub

Reply via email to