deploy: Pull bound images before staging via composefs mount - #2290
deploy: Pull bound images before staging via composefs mount#2290cgwalters wants to merge 3 commits into
Conversation
|
Needs |
d754a3e to
198b725
Compare
198b725 to
599b688
Compare
599b688 to
330bcb9
Compare
Looks legit |
40b03f3 to
74f6c22
Compare
|
OK, this one should be good to go now |
|
Hmm, hitting #2340 on this on centos-9. |
8207128 to
74c96e9
Compare
|
OK this rolls in the fix for that |
74c96e9 to
1dcfd17
Compare
|
Looks like there are some potential latent issues with general tests on c9s |
…ck fallback
CentOS Stream 9 ships kernel 5.14, which cannot mount an erofs image
directly from a file descriptor. composefs-rs provides a `rhel9` feature
in composefs-ctl (and forwarded through bootc-initramfs-setup) that works
around this by loopifying the image file into a /dev/loopN block device
before mounting it.
Without this feature enabled at build time, bootc install on centos-9 with
the composefs backend fails with ENOTBLK ('Block device required', errno 15)
when the initramfs setup code tries to mount the composefs/erofs image.
Wire up the feature in two places:
- Makefile: extend CARGO_FEATURES_DEFAULT to also emit `rhel9` when
building on a RHEL-like OS with VERSION_ID=9.
- bootc.spec: add a `rhel9` bcond gated on `%{?rhel} == 9` and pass
it to all three cargo build invocations and to %make_install.
With the build fix in place, remove the ci.yml exclude that was
suppressing centos-9 + composefs testing in test-integration.
Closes: bootc-dev#1812
Assisted-by: AI
Signed-off-by: Colin Walters <walters@verbum.org>
A bound-image pull failure must not leave a deployment queued for reboot. Read bound-image specifications from a safe temporary checkout of the imported commit and pull them before staging; repeat the pull when applying a download-only deployment before unlocking finalization. The TMT coverage forces a pull failure, verifies no deployment is staged, and retries successfully. Closes: bootc-dev#2013 Assisted-by: AI Signed-off-by: Colin Walters <walters@verbum.org>
1dcfd17 to
033a6c4
Compare
|
I don't yet have an idea of what's going on with the shadow generator here, looking |
In what turns out to be a GIANT trap, systemd generators on RHEL9 may run before a writable /tmp is available. Assisted-by: https://github.com/cgwalters/cgwalters#llms Signed-off-by: Colin Walters <walters@verbum.org>
| // bootc's command helpers run from a systemd generator. Generators on | ||
| // systemd 252 and older may see a read-only /tmp (253+ provides a private | ||
| // writable /tmp), so output capture must not rely on filesystem temp files. |
There was a problem hiding this comment.
This took SO MUCH time to figure out
CentOS Stream 9 composefs/virtiofs investigationSummaryThe affected CI configuration is: The visible last line in failed jobs was often: Trace logging from a preserved local hang proved that both Neither serializing composefs layer work nor locking bootc's current mappings Full investigation detailsUnless noted otherwise, evidence paths are relative to the CI observations
Representative PR #2290 attempts:
The install-stage failure is intermittent. The complete job has not been shown The key run used bcvk 0.19.0. Updating from local bcvk 0.18.0 to 0.19.0 changed bcvk topologyThe installer sets: Both virtiofsd exports normally use Preserved hang evidenceThe strongest capture is under: It shows:
This refutes ESP formatting, partition scanning, udev settlement, and RHEL 9 The stack proves a file-backed page fault, but not which mapping faulted. The No useful kernel error was captured. Preserved host In a later live stall, QEMU remained runnable and consumed CPU while both ExperimentsTrue composefs concurrencyComposefs-rs v0.9 has separate semaphores for repository object writes and
The serialized stall had confirmed activation. Fisher's exact test was Evidence is under the sibling worktree: Locking bootc mappingsAn experimental branch calls
Mlock itself completed in 6–9 ms in focused tests. Since three fully activated
Plain ephemeral/manual pathA plain
That run completed. The tar-split file read in milliseconds, the image copy Summary: Virtiofs cache modesTemporary bcvk instrumentation varied rootfs and AIS cache modes independently. The sample was not a controlled statistical matrix, so cache mode remains a Guest-local OCI stagingThe only reliable workaround was an opt-in bcvk prototype that:
At least ten controlled staged installs, plus two independent review runs, Prototype: This is a workaround, not proof of the lower-level cause. It adds full-image Separate sealed-upgrade failureWhen installation completes, CentOS 9 cannot use bcvk's normal It generates an unsigned replacement UKI. Secure Boot then reports: This deterministic reboot failure is separate from the intermittent direct-pull Timeout and cleanup lessons
Current conclusionThe failure is intermittent and was observed during bcvk The evidence is consistent with a guest virtiofs/page-cache failure under this Recommended next steps:
|
We were still staging a new bootloader entry even when we failed to pull a LBI. Switch to only doing an image pull and not a deployment, then pulling referenced LBIs from that.
Closes: #2013