Skip to content

composefs: Complete opt-in boot counting coverage - #133

Draft
cgwalters-bot wants to merge 1 commit into
cgwalters-forge:mainfrom
cgwalters-bot:dispatch/implement/agent-run-43554107027
Draft

cgwalters-bot wants to merge 1 commit into
cgwalters-forge:mainfrom
cgwalters-bot:dispatch/implement/agent-run-43554107027

Conversation

@cgwalters-bot

Copy link
Copy Markdown
Collaborator

Executive summary

Superseding draft for #25: reuse its counting implementation (a65adf3, 346a662, f1ac557) on the admitted base and extend BLS/UKI wrapper tests and failure-detection docs. Counting prevents an unbootable staged deployment from remaining the default indefinitely; it stays opt-in through the running host's /etc/kernel/tries. Leave #25's branch and closing decision untouched.

Part of #131

Re-read #65 and #122; boot-complete is not included or superseded. Failed-assessment/prevented-blessing checks with #122 remain an integration gate. Exhaustion is simulated by renaming the wrapper, not three real failed boots. Explicit rollback keeps its existing uncounted behavior; GRUB, aboot and soft-reboot policy are unchanged. The test alone sets tries=3 and installs the local SELinux rename workaround; no stock-policy readiness, policy publication or default enablement is claimed.

Verification and remaining gates

Tested head: 0ca885f plus this uncommitted patch. cargo test -p bootc-lib counted_entries --lib (2), cargo test -p bootc-lib boot_counting --lib (3), cargo test -p bootc-lib test_type1_filename_generation --lib (1), cargo test -p bootc-lib --lib --quiet (338 passed, 1 ignored), cargo xtask update-generated direct, cargo xtask update-generated direct --check, cargo fmt --all --check, and git diff --check: exit 0.

just validate and just unit-tests: exit 1, container startup failed with crun sd-bus error. just test-composefs systemd ext4 bls unsealed composefs-boot-counting and just test-composefs systemd ext4 uki sealed composefs-boot-counting: exit 1 at the same container build prerequisite. Direct cargo xtask run-tmt --env=BOOTC_variant=composefs --composefs-backend --bootloader=systemd --filesystem=ext4 --boot-type=bls --seal-state=unsealed localhost/bootc composefs-boot-counting and the corresponding --boot-type=uki --seal-state=sealed command: exit 1, bcvk missing.

No guest ran. Intended guests: CentOS Stream 10, composefs v1, systemd-boot, ext4, BLS/unsealed and UKI/sealed with test Secure Boot keys. Host lacks bcvk, tmt, virsh and runner access to /dev/kvm. Runtime blessing, fallback, rollback and GC proof on this head remains outstanding; #25's historical passes are not refreshed-head proof. A temporary #122 integration build was not feasible with these prerequisites missing.

Review: one adversarial pass, no blockers; important follow-ups are systemd-boot INT_MAX counter alignment, nonfatal invalid-UTF-8 tries handling, and observing a real decrement while blessing is prevented.

Publication dependency: fork default is forge; this proposal uses admitted base main rather than bypassing caller bounds. Maintainer rebase/retarget to forge is required for a default-branch replacement. No upstream posting, branch rewrite or approval-boundary change.

Generated by dispatch · ◷

An unbootable staged deployment should not remain the default
indefinitely. Honor /etc/kernel/tries on updates to systemd-boot
deployments, using the shared Type 1 writer for both BLS and UKI.
Limit counting to the ESP because older loaders cannot decrement
counters on XBOOTLDR.

Part of cgwalters-forge#131

Unit tests passed; container and VM checks hit the same crun sd-bus
startup failure as unchanged main.

Assisted-by: https://github.com/cgwalters/cgwalters#llms
@cgwalters-bot

cgwalters-bot commented Dec 2, 2026 •

Copy link
Copy Markdown
Collaborator Author

Rebase round 1 of 2 for ccdb20cea2d7: run.

Generated-by: https://github.com/cgwalters/#llms

@cgwalters-bot

cgwalters-bot commented Dec 2, 2026 •

Copy link
Copy Markdown
Collaborator Author

✅ dispatch ended well. Result: #133

@cgwalters-bot
cgwalters-bot force-pushed the dispatch/implement/agent-run-43554107027 branch from ccdb20c to 4a49fc0 Compare December 2, 2026 00:41
@cgwalters-bot

Copy link
Copy Markdown
Collaborator Author

Fix run report:

Three review passes found no remaining rebase blocker, but an inherited UKI compatibility issue still needs resolution before merge.

{"schema":"agent-board/recommendation/v1","pr":133,"head":"4a49fc0f131d4ebf3cdd3c07aadf8f0af27b08a2","action":"operator_question","reason":"An installed systemd-boot loader can fail to decrement a UKI wrapper selected using a different userspace systemd version.","detail":{}}

Generated-by: https://github.com/cgwalters/#llms

Generated by dispatch · ◷

@cgwalters-bot

Copy link
Copy Markdown
Collaborator Author

✅ dispatch ended well. Result: #133

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant