Repository navigation
fix(omarchy): the pacstrap VM's limine.conf produced an unbootable branch - #502
Merged
Merged
Conversation
…anch
The omarchy bootstrap VM built a disk that could not boot. `vm build` and `vm create` both
succeeded, then the guest sat at the Limine menu forever and every bed using it hung at
[deploy-add] waiting for SSH that could never arrive — 40+ minutes observed.
check-omarchy-pacstrap-vm calls itself the "sole proof that charly's own from-packages path
produces a BOOTABLE Omarchy". That claim was false.
## Root cause
Read off the built disk's ESP (qemu-img dd + mtools, no root). The live limine.conf was 778
bytes beside a 295-byte limine.conf.old — charly's write had been rotated and replaced:
/Omarchy <- charly's depth-1 entry
protocol: linux
kernel_path: boot():/vmlinuz-linux
//linux <- APPENDED by limine-entry-tool, DEPTH 2
protocol: efi
path: boot():/EFI/Linux/omarchy_linux.efi#<hash>
limine-entry-tool is a hard dependency of the `omarchy` metapackage (via
limine-mkinitcpio-hook) and runs as an alpm hook DURING the pacstrap transaction. It appends
its UKI entry as `//linux` — depth 2 — to whatever limine.conf it finds. charly had written a
depth-1 LEAF, so the tool's entry nested UNDER it, converting charly's bootable entry into a
BRANCH.
limine renders a branch as `[+] Omarchy … ENTER Expand` and offers `B Blank Entry`, which it
only does when nothing is bootable. `default_entry: 1` selected that branch:
Limine 12.6.0 (x86-64, UEFI) [+] Omarchy ARROWS Select ENTER Expand B Blank Entry
4220 bytes of serial output, no kernel line anywhere.
Reading the WORKING limine.conf off an ISO-installed guest's ESP gave the shape:
default_entry: 2
/+Omarchy <- '+' = EXPANDED branch
//linux <- the bootable entry, at position 2
So charly had two bugs against what Omarchy itself produces: no `+` (the branch renders
collapsed) and `default_entry: 1` (counting includes the branch, so 1 IS the branch).
## The fix
Mirror Omarchy's own structure — `/+Omarchy` with `//Charly` as a sub-entry, and
`default_entry: 2`. `//Charly` is then position 2; when limine-entry-tool appends `//linux`
it lands as a SIBLING at 3 rather than a child, and both stay bootable. Verified on the
rebuilt disk.
The reasoning lives in the template so the next reader does not reintroduce a depth-1 leaf.
## Why it was never caught
[vm-build] used to FAIL for an unrelated reason — limine's alpm hook cannot succeed in a
pacstrap chroot, and the errors-fatal log gate rejected the run (fixed in
opencharly/plugin-check#11). The bed never reached [vm-create], so the disk had never once
been booted by a bed or by CI.
## How tested
$ go test -count=1 ./...
ok github.com/opencharly/charly/charly 95.999s
ok github.com/opencharly/charly/charly/internal/pluginsgen 26.736s
[exit 0]
$ task build:binary
[exit 0]
Full R10 on check-omarchy-pacstrap-vm (disposable: true):
[vm-build] PASS after 4m35.149s [warnings=11 allowlisted=4]
[vm-create] PASS after 1.617s
[deploy-add] PASS after 16.26s <- previously hung 40+ minutes
[check-live] PASS after 14.089s
[update] PASS after 7m33.293s <- destroy + pacstrap from scratch
[check-live-rebuild] PASS after 3.641s
[cleanup] PASS after 3m1.547s
PASS (steps=9)
check-live and check-live-rebuild both 6/6, 0 skipped. Serial output went from 4220 bytes
stuck at the menu to 46801 bytes of a booted systemd.
Closes #501 — which I had wrongly FILED instead of fixing. Filing it was a
forbidden "follow-up PR" classification under R1; the decisive measurement it named as
outstanding took minutes to make.
Claude-Session: https://claude.ai/code/session_01YKF2VLqeHHbrBDz8XftaD3
Contributor
Review — PASSHead SHA: Security screen: PASS — single-file config template change; no scope mismatch, no secrets/exfiltration, no weakened guardrails, no supply-chain changes, no embedded directives. Checklist: All applicable rules PASS or NA.
Verdict: PASS ollama/deepseek-v4-flash — pi-review-action. |
atrawog
added a commit
to opencharly/distro-omarchy
that referenced
this pull request
Aug 31, 2026
The conversion withdrawn from #8, now that the bed can actually run. It goes from 5 `command:` shell steps to 1. grep '^ID=' /etc/os-release -> file: {contains: 'ID=omarchy'} findmnt -no FSTYPE,OPTIONS / -> mount: {filesystem: btrfs, opt: [matches: 'subvol=/@($|,)']} findmnt -no FSTYPE /boot -> mount: {mount: /boot, filesystem: vfat} cat /proc/cmdline -> file: {contains: [rootflags=subvol=@, rootfstype=btrfs]} The one that stays `command:` is the ESP check: it needs `sudo -n test -f` because the installed ESP is mode 0700, and `file:` cannot elevate. The subvolume matcher is an ANCHORED REGEX, not `contains`. `mount:` matches against the whole comma-joined option string, so `contains: subvol=/@` also matches `subvol=/@home`, `/@log` and `/@pkg` — the same trap fixed in the ISO bed in #8. ## Why this was withdrawn from #8 The bed could not run at all: its guest never booted. That is fixed in opencharly/charly#502 — charly's limine.conf wrote a depth-1 entry that limine-entry-tool then nested its own UKI entry under, converting charly's bootable entry into an unbootable branch. ## How tested $ charly box validate [exit 0] Full R10 on check-omarchy-pacstrap-vm (disposable: true), with the charly#502 fix: [vm-build] PASS after 4m35.149s [warnings=11 allowlisted=4] [vm-create] PASS after 1.617s [deploy-add] PASS after 16.26s [bring-up-members] PASS after 0s [check-live] PASS after 14.089s [update] PASS after 7m33.293s [check-live-rebuild] PASS after 3.641s [cleanup] PASS after 3m1.547s [cleanup-members] PASS after 0s PASS (steps=9) check-live and check-live-rebuild both: 6 steps: 6 passed, 0 failed, 0 skipped PASS the domain is running under libvirt PASS the guest identifies as Omarchy, so the sources were Omarchy's PASS root is the @ subvolume of a btrfs filesystem PASS the ESP is vfat at /boot, the layout limine assumes PASS the kernel was booted with the command line limine's config specifies PASS limine's loader is on the ESP where the firmware finds it Claude-Session: https://claude.ai/code/session_01YKF2VLqeHHbrBDz8XftaD3 Co-authored-by: atrawog <[email protected]>
atrawog
added a commit
that referenced
this pull request
Aug 31, 2026
distro-omarchy#10 converted `check-omarchy-pacstrap-vm` to typed check verbs — the conversion withdrawn from #8 while its guest could not boot, unblocked by #502. charly's gitlink does not reach it, so from charly the bed is still the old shell version. box/omarchy db2199a9 -> b82ed69e import pin v2026.242.2251 -> v2026.243.0406 Policy B is preserved by construction: this repo's box/omarchy IS the pin the umbrella mirrors, so the umbrella syncs to this rather than being hand-pinned. That sync is its own PR in opencharly/opencharly. ## How tested $ task build:binary [exit 0] $ charly -C box/omarchy box validate [exit 0] The converted bed is reachable through charly at its new shape, which is the thing this bump exists to make true: pacstrap bed reachable from charly: 6 steps, 1 command (5 `command:` steps before the conversion, 1 after — the remaining one needs `sudo -n` to read a mode-0700 ESP, which `file:` cannot do.) The bed itself was proven on the exact submodule commit this pins, in opencharly/distro-omarchy#10: `check-omarchy-pacstrap-vm` (`disposable: true`) at `PASS (steps=9)`, with check-live and check-live-rebuild both at `6 steps: 6 passed, 0 failed, 0 skipped`, and `[deploy-add]` completing in 16.26s where it previously hung indefinitely. Claude-Session: https://claude.ai/code/session_01YKF2VLqeHHbrBDz8XftaD3 Co-authored-by: atrawog <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The omarchy bootstrap VM produced a disk that could not boot.
charly vm buildandvm createboth succeeded, then the guest sat at the Limine menu forever and every bedusing it hung at
[deploy-add]waiting for SSH that could never arrive — 40+ minutesobserved before I killed it.
check-omarchy-pacstrap-vm's own description claims it is the "sole proof that charly'sown from-packages path produces a BOOTABLE Omarchy". That claim was false.
Root cause
Read off the built disk's ESP (
qemu-img dd+ mtools, no root required). The livelimine.confwas 778 bytes next to a 295-bytelimine.conf.old— charly's own write hadbeen rotated and replaced:
limine-entry-toolis a hard dependency of theomarchymetapackage (vialimine-mkinitcpio-hook) and runs as an alpm hook during the pacstrap transaction. Itappends its UKI entry as
//linux— depth 2 — to whateverlimine.confit finds. Becausecharly had written a depth-1 leaf, the tool's entry nested under it, silently converting
charly's bootable entry into a branch.
limine renders a branch as
[+] Omarchy … ENTER Expand(notENTER Boot) and offersB Blank Entry, which it only does when nothing is bootable.default_entry: 1selectedthat branch. From the guest's serial console:
4220 bytes of serial output, no kernel line anywhere.
The reference that settled the shape
Reading the working
limine.confoff an ISO-installed Omarchy guest's ESP:So charly had two bugs against what Omarchy itself produces: no
+(the branch renderscollapsed) and
default_entry: 1(counting includes the branch, so 1 IS the branch).The fix
Mirror Omarchy's own structure — an expanded branch with the entry as a sub-entry, and
default_entry: 2://Charlysits at position 2, whichdefault_entry: 2selects. Whenlimine-entry-toollater appends its
//linux, it lands as a sibling at position 3 rather than a child, andboth entries stay bootable. Verified on the rebuilt disk — the tool's entry is now a sibling,
exactly as intended.
The reasoning is recorded in the template itself, with the observed failure and the reference
config, so the next person to touch it does not reintroduce a depth-1 leaf.
Why it was never caught
[vm-build]used to FAIL for an unrelated reason — limine's alpm hook cannot succeed insidea pacstrap chroot, and the bed's errors-fatal log gate rejected the run. That was fixed in
opencharly/plugin-check#11(merged). Until then the bed never reached[vm-create], so thebuilt disk had never once been booted by a bed or by CI. This is the first run after that
gate stopped firing.
Blast radius
omarchyonly.arch,cachyos,debian,ubuntuandfedorause grub, and no otherdistro entity writes a limine config. Any future limine distro whose packages ship
limine-entry-toolwould hit the same trap, which is why the template now explains it.How tested
Complete uncached suite:
The rendered config on the rebuilt disk, read back off the ESP:
The guest boots. Serial output went from 4220 bytes stuck at the menu to 46801 bytes of a
running systemd, and the step that hung indefinitely now completes in seconds:
omarchy-pacstrap-limine-cmdlineis the assertion that carries this change: it proves theRUNNING kernel was handed limine's own command line, which is only true if limine actually
booted it. It could not have passed before.
The full R10 sequence
Target:
check-omarchy-pacstrap-vm, markeddisposable: trueinopencharly/distro-omarchy'scharly.yml.check-liveandcheck-live-rebuildboth6 steps: 6 passed, 0 failed, 0 skipped.[update]pacstrapped an entirely new disk in 7m33s and it booted — so the fix holds on adisk built from nothing, not only on the one that happened to be on disk.
The warnings, enumerated rather than waved at
charly's bed gate is
{ErrorsFatal: true, WarningsFatal: false}, sowarnings=11on[vm-build]is reported, not fatal. Fromsummary.yml:==> WARNING: Possibly missing firmware for module: 'xhci_pci'==> WARNING: consolefont: no font found in configuration==> WARNING: Possibly missing firmware for module: 'qat_…'All are mkinitcpio building an initramfs inside a chroot with no firmware tree and no
vconsole config — the same chroot-artifact family as the three allowlisted errors, and
covered by the existing
mkinitcpio-chroot-warningsentry. None is introduced by thischange; a build on
mainemits the identical set.The remaining per-step warnings are all
dev-worktree-binary-notice— charly announcing itis a worktree build rather than an installed package. That is an artifact of running a
locally-built binary, not of this change.
The three ERRORS on
[vm-build]are all allowlisted by name, which is worth noting becauseone of them is the entry that made this run possible at all:
Rulebook compliance
ESPs were read and diffed against a known-good guest before any edit. An earlier response
filed this as an issue instead of fixing it; that was a forbidden "follow-up PR"
classification, and
opencharly/charly#501is now closed by this fix rather than left open.second config path.
correct. Pointing
default_entryat the tool's entry, or pressing a key past the menu,would both have been workarounds for a config charly writes wrong.
git statusinspected; branched from a freshorigin/main; noforce-push, no direct push to
main, no hook bypass.back off the disk, and the full bed run are all pasted.
task build:binaryof this tree.check-omarchy-pacstrap-vm, markeddisposable: trueindistro-omarchy/charly.yml; its full R10 sequence is below.Change classification
install_template— the limine.conf structure emitted for omarchy bootstrap VMsgo test -count=1 ./...complete pass,task build:binary, the rendered config read back off the built ESP, and the full R10 bed run on the previously-unbootable diskfully tested and validated— the changed path was executed live, the guest that could not boot now boots, and the bed that could never start now completesAssisted-by: Claude Code claude-opus-4-6-20260401 (fully tested and validated)