-
Notifications
You must be signed in to change notification settings - Fork 61
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support MBR disks as boot devices #6
Comments
OK I will have a look at supporting filesystem as well as partition UUIDs. Could you pls attach a diff of your workaround |
https://gist.github.com/reanimus/881876812cb38a19aa9f7a0431ee92ed This essentially makes all disks use FS UUIDs instead of the partition ones. It also doesn't account for different combinations of other options beyond having the keyfile on the boot USB. I also don't know how that affects the functionality beyond basic kernel build/copying to key. |
Hi, |
31 Oct 2020: sadly, due to legal obligations arising from a recent change in my 'real world' job, I must announce I am standing down as maintainer of this project with immediate effect. For the meantime, I will leave the repo up (for historical interest, and it may be of use to others); however, I plan no further updates, nor will I be accepting / actioning further pull requests or bug reports from this point. Email requests for support will also have to be politely declined, so, please treat this as an effective EOL notice. |
As it stands, the configuration for buildkernel is completely oriented toward devices that use GPT disks. This is fine (mostly), but it's caused issues for me as I use a USB key as a boot device, but also wish to use it as a data drive. Unfortunately, Windows doesn't seem to support GPT USB disks with EFI system partitions on them (as it seems to cause some weird funkiness where it tries to treat it as a single-partition disk but chooses the ESP as the partition it shows). As such, I can't use a disk with a proper EFI system partition and a separate data partition.
My solution to this is to initialize the disk as an MBR disk, create a FAT32 partition on it, and simply place the EFI directory/files/keyfile on it. It's not perfect (there's no separate partition where the boot stuff is stored separately), but it works enough for me to use the drive as both a boot key and a data drive. My EFI seems to accept these disks (and I've found most EFI implementations are fairly forgiving of MBR boot disks)
However, in order to do this with buildkernel, I've gone in and implemented a kludge. Since MBR disks have no partition UUID, you can't provide one for buildkernel to use. As a workaround, I changed
PARTUUIDDEVDIR
to point to/dev/disk/by-uuid/
rather than/dev/disk/by-partuuid
. This uses the filesystem UUID, which both the LUKS partition and the boot key have. I also disable the lowercase fixing for the boot partition, as FAT32 UUIDs are uppercase.Would it be possible to have more formal support for filesystem UUIDs? This kludge is a bit of an annoyance to go in and add and I also feel it would be useful for others in a similar situation.
The text was updated successfully, but these errors were encountered: