C.J. Collier: Finding: Promoting SeaBIOS Cloud Images to UEFI Secure Boot (Proxmox)
Discovery
Legacy cloud templates often lack the partitioning and bootloader
binaries required for UEFI Secure Boot. Attempting to switch such a VM
to OVMF in Proxmox results in not a bootable disk. We discovered that
a surgical promotion is possible by manipulating the block device and
EFI variables from the hypervisor.
The Problem
- Protective MBR Flags: Legacy installers often set
the pmbr_boot flag on the GPT s protective MBR. Strict UEFI
implementations (OVMF) will ignore the GPT if this flag is present.
- Missing ESP: Cloud images often lack a FAT32 EFI
System Partition (ESP).
- Variable Store: A fresh Proxmox
efidisk0 is empty and lacks both the trust certificates
(PK/KEK/db) and the BootOrder entries required for an automated
boot.
The Promotion Rule
To upgrade a SeaBIOS VM to Secure Boot without a full OS reinstall:
1. Surgical Partitioning: Map the disk on the host and
add a FAT32 partition (Type EF00). Clear the
pmbr_boot flag from the MBR. 2. Binary
Preparation: Boot the VM in SeaBIOS mode to install
shim and grub-efi packages. Use
grub2-mkconfig to populate the new ESP. 3. Trust
Injection: Use the virt-fw-vars utility on the
hypervisor to programmatically enroll the Red Hat/Microsoft CA keys and
any custom certificates (e.g., FreeIPA CA) into the VM s
efidisk. 4. Boot Pinning: Explicitly set
the UEFI BootOrder to point to the shimx64.efi
path via virt-fw-vars --append-boot-filepath.
Solution (Example Command
Sequence)
On the Proxmox Host (root):
# Map and Clean MBR
DEV=$(rbd map pool/disk)
parted -s $DEV disk_set pmbr_boot off
# Inject Trust and Boot Path (VM must be stopped)
virt-fw-vars --inplace /dev/rbd/mapped_efidisk \
--enroll-redhat \
--add-db <GUID> /path/to/ipa-ca.crt \
--append-boot-filepath '\EFI\centos\shimx64.efi' \
--sb
This workflow enables high-integrity Secure Boot environments using
existing SeaBIOS infrastructure templates.
- Protective MBR Flags: Legacy installers often set
thepmbr_bootflag on the GPT s protective MBR. Strict UEFI
implementations (OVMF) will ignore the GPT if this flag is present. - Missing ESP: Cloud images often lack a FAT32 EFI
System Partition (ESP). - Variable Store: A fresh Proxmox
efidisk0is empty and lacks both the trust certificates
(PK/KEK/db) and the BootOrder entries required for an automated
boot.
The Promotion Rule
To upgrade a SeaBIOS VM to Secure Boot without a full OS reinstall:
1. Surgical Partitioning: Map the disk on the host and
add a FAT32 partition (Type EF00). Clear the
pmbr_boot flag from the MBR. 2. Binary
Preparation: Boot the VM in SeaBIOS mode to install
shim and grub-efi packages. Use
grub2-mkconfig to populate the new ESP. 3. Trust
Injection: Use the virt-fw-vars utility on the
hypervisor to programmatically enroll the Red Hat/Microsoft CA keys and
any custom certificates (e.g., FreeIPA CA) into the VM s
efidisk. 4. Boot Pinning: Explicitly set
the UEFI BootOrder to point to the shimx64.efi
path via virt-fw-vars --append-boot-filepath.
Solution (Example Command
Sequence)
On the Proxmox Host (root):
# Map and Clean MBR
DEV=$(rbd map pool/disk)
parted -s $DEV disk_set pmbr_boot off
# Inject Trust and Boot Path (VM must be stopped)
virt-fw-vars --inplace /dev/rbd/mapped_efidisk \
--enroll-redhat \
--add-db <GUID> /path/to/ipa-ca.crt \
--append-boot-filepath '\EFI\centos\shimx64.efi' \
--sb
This workflow enables high-integrity Secure Boot environments using
existing SeaBIOS infrastructure templates.
Sequence) On the Proxmox Host (
root):
# Map and Clean MBR
DEV=$(rbd map pool/disk)
parted -s $DEV disk_set pmbr_boot off
# Inject Trust and Boot Path (VM must be stopped)
virt-fw-vars --inplace /dev/rbd/mapped_efidisk \
--enroll-redhat \
--add-db <GUID> /path/to/ipa-ca.crt \
--append-boot-filepath '\EFI\centos\shimx64.efi' \
--sb
existing SeaBIOS infrastructure templates.
The first install of a Gentoo kernel needs to be somewhat manual if you want to optimize the kernel for the (virtual) system it boots on.
In
The kernel should auto-build once new versions become available via portage.
Again the
As promised, on this post I m going to explain how I ve configured this blog
using
I have been using
For the last years, I have been using btrfs in a completely naive way, simply creating new filesystems, mounting them, moving data over, linking the directories into my home dir, etc etc. It all became a huge mess over time. I have heard of
All in all, a very smooth transition, and at least for some time I don t have to worry about which partition has still some space left.
Thanks btrfs and Open Source!
Here is my monthly update covering what I have been doing in the free software world (

I've been doing a little bit of dynamically typed programming in Haskell,
to improve
Hi all,
After 4 release candidates, the FusionForge community is proud to
announce the new major Fusionforge 6.0 final release.
The major changes in this version are:


Error -36 seems to be a generic I/O error in OSX and you can find many hits when you do a search in your favorite search engine. The Apache logs report lots of these lines:
Various people observed in a
We have started to look into