You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
fix(pod): a rootless pod fails to start with mount_setattr on the injected nvidia-cuda-mps-control #1278
category:runtimeThe host/framework, loader/provider registration, or a cross-cutting contract.type:fixA named defect in existing behavior; a violated rule of the rulebook or design.
the pod deploy's CDI/device injection path (plugin-deploy-pod + the nvidia CDI spec): a rootless container must not attempt mount_setattr on an injected MPS binary, or must drop/replace that injection; document the required host condition
Cited design decision or org-rulebook rule (or none)
R1
Symptom
charly start comfyui-cdi fails at container creation; the unit exits 126:
conmon a978dfbfe9f15aca5c53 <error>: Failed to create container: exit status 1
charly-comfyui-cdi[894731]: Error: crun: mount_setattr `/usr/bin/nvidia-cuda-mps-control`:
Operation not permitted: OCI permission denied
charly-comfyui-cdi.service: Main process exited, code=exited, status=126/n/a
What this is not
Not the volume: the deployment had just moved from a named volume to a bind
(Volume=/home/atrawog/.local/share/charly/models/comfyui:/home/user/ComfyUI) and the failing call
names the injected NVIDIA MPS binary, not that bind. The same error class would appear with any
volume backing.
Why it matters
The pod is unrecoverable through charly: charly start re-invokes the unit and the unit dies at
container creation, so systemctl --user reset-failed changes nothing. Rootless CDI injection of the
MPS control binary now attempts a mount_setattr the user namespace refuses.
What this issue owns
Establish which host condition changed (driver/CDI spec regeneration injecting the MPS binary into
the container mount list) — measured, not assumed.
Make the injection work under rootless podman, or exclude the MPS binary with a documented reason.
Fail with a message that names the fix, instead of a 126 and a pointer at systemctl.
Observed concurrently
The same outage window included a bed run that deployed a container under the LIVE name charly-comfyui-cdi (opencharly/distro-cachyos#251). That is a separate defect; this issue is the
mount_setattr failure that keeps the pod down afterwards.
Filed issues
None separate: this is the finding.
Agent: image-lane-vram · Claude Code session 739c9baf-e4cc-465c-9028-0a77b9ea7617 Assisted-by: Claude Code deepseek-v4.1-flash:cloud (analysed on a live system)
STATUS — root-caused to a host-side CDI regeneration, with the timestamps measured.
/etc/cdi/nvidia.yaml regenerated 2026-11-24T23:59 (grep -c nvidia-cuda-mps-control → 2)
charly-comfyui-cdi active-enter 2026-11-24T21:38:59 (BEFORE that regeneration)
nvidia-cdi-refresh.path active (waiting) — triggers on NVIDIA driver/toolkit events
nvidia-cdi-refresh.service ran and wrote the new spec
So: a CDI refresh fired at ~23:59, the regenerated spec injects /usr/bin/nvidia-cuda-mps-control, and
rootless container creation now fails on mount_setattr for it. The failure is a property of the spec plus rootless podman, not of this image or its volume — any rootless GPU pod created
after 23:59 hits it; a container that already exists (e.g. the ollama pod) keeps running.
That reframes the fix into two candidate arms, and the choice should be measured, not guessed:
Spec-side: regeneration should not inject an MPS binary that rootless cannot mount (nvidia-ctk
flag or a filtered generate step), or
podman-side: the deploy must tolerate the injection (cgroup/userns option) — measured against a
container that starts fine before the refresh.
Either way, charly start cannot recover today: the unit dies at container creation, so no reset or
retry helps, and the error text points only at systemctl.
Next update: on any event, or when the spec/rootless interaction is measured against a control case.
Agent: image-lane-vram · Claude Code session 739c9baf-e4cc-465c-9028-0a77b9ea7617 Assisted-by: Claude Code deepseek-v4.1-flash:cloud (analysed on a live system)
So the chain is: this candy regenerates /etc/cdi/nvidia.yaml on deploy → the generated spec injects /usr/bin/nvidia-cuda-mps-control as a read-only hostPath → rootless crun cannot mount_setattr a
file mount there → container creation fails with status 126.
Measured corroboration: I removed the entry by hand at 02:0x; the next charly start rewrote the
file at 02:11:17 (the same second as the failing create) and the error returned verbatim. A hand patch
therefore cannot survive — the fix belongs in this candy.
Candidate fixes, to be decided by measurement:
filter nvidia-cuda-mps*/.mps hostPath entries out of the generated spec (post-process), or
pass the generator's own flag that omits MPS (if the installed nvidia-ctk has one — check its cdi generate --help), or
keep the entry and make the deploy tolerate it under rootless (userns/cgroup option) — the option
that needs a control case.
Second, separate finding from the same second: the create used image=ghcr.io/opencharly/comfyui-cdi:check-cachyos-comfyui-pod-2026.328.2011 — the BED image — for the
LIVE deployment named charly-comfyui-cdi. That is the opencharly/distro-cachyos#251 collision, and it
means the live deployment's image may currently be wrong as well; it must be reset before any restart is
believed.
Agent: image-lane-vram · Claude Code session 739c9baf-e4cc-465c-9028-0a77b9ea7617 Assisted-by: Claude Code deepseek-v4.1-flash:cloud (analysed on a live system)
STATUS — fix site located, and the filter is proven against a freshly generated spec.
Call site: the sudo command I captured is emitted by plugin-gpu/candy/plugin-gpu/switch.go
(mkdir -p /etc/cdi + nvidia-ctk cdi generate --output=/etc/cdi/nvidia.yaml). It is the GPU
capability plugin that regenerates the spec during a deploy/start, which is why a hand-patched spec is
overwritten in the same second and the pod cannot start again.
Filter, proven on a real spec (no host state touched):
So the fix in plugin-gpu is: generate, then drop the nvidia-cuda-mps* hostPath items before
writing the file — rootless crun cannot mount_setattr a FILE injection and no charly pod uses MPS.
The generator offers no flag for it (checked nvidia-ctk cdi generate --help, 1.20.1: --disable-hook, --mode, --no-all-device exist; none excludes host-file injections).
State of the pod: still down, and it cannot be recovered host-side — every charly start re-runs
that generation. It also currently resolves a BED image
(…:check-cachyos-comfyui-pod-2026.328.2011) for the live deployment, which must be reset to 2026.328.1642 once this fix lands (distro-cachyos#251).
Agent: image-lane-vram · Claude Code session 739c9baf-e4cc-465c-9028-0a77b9ea7617 Assisted-by: Claude Code deepseek-v4.1-flash:cloud (analysed on a live system)
CLAIM — owned by this session as the comfyui/EPERM leg of the CDI audit (opencharly/opencharly#1287). Close after the measured spike plus a re-created comfyui-cdi under keep-id.
Agent: cdi-audit · Claude Code session f760307f-53b4-4f48-87da-00f95e5300ed Assisted-by: Claude Code deepseek-v4.1-flash:cloud (documentation reviewed)
RESOLVED — the failure mode is gone, and it is gone structurally rather than by a friendlier message.
The mount_setattr EPERM came from a ROOTLESS container being handed the STOCK CDI spec, whose /usr/bin/nvidia-cuda-mps-control entry is a read-only FILE mount:
$ grep -c nvidia-cuda-mps-control /etc/cdi/nvidia.yaml → 2 (the stock spec the unit used to get)
A deploy carrying a bind volume now runs under keep-id against the DERIVED devices-only spec, which keeps the device nodes and drops every mount and hook:
so there is no file mount left for mount_setattr to refuse. Measured live on the merged tree, twice in one run (fresh create AND a destroy→regenerate→start rebuild), via charly check run check-pod-cdi-userns (opencharly/plugin-deploy-pod#105): PASS (steps=6), pc-userns-keepid-user … exit=0, with the emitted unit read from disk as UserNS=keep-id:uid=1000,gid=1000 + PodmanArgs=--cdi-spec-dir …/.local/share/charly/cdi, and the bind written from inside the container as uid 1000.
Item 3 of "What this issue owns" (a message that names the fix) is therefore moot for this class — the 126 is unreachable for a CDI pod, because the spec it is handed no longer carries the offending mount. charly-comfyui-cdi itself is on that shape now: AddDevice=nvidia.com/gpu=all, PodmanArgs=--cdi-spec-dir /home/atrawog/.local/share/charly/cdi, UserNS=keep-id:uid=1000,gid=1000.
Agent: cdi-audit · Claude Code session f760307f-53b4-4f48-87da-00f95e5300ed Assisted-by: Claude Code deepseek-v4.1-flash:cloud (fully tested and validated)
category:runtimeThe host/framework, loader/provider registration, or a cross-cutting contract.type:fixA named defect in existing behavior; a violated rule of the rulebook or design.
Activity
aitrawog commentedon Nov 24, 2026
STATUS
STATUS — root-caused to a host-side CDI regeneration, with the timestamps measured.
So: a CDI refresh fired at ~23:59, the regenerated spec injects
/usr/bin/nvidia-cuda-mps-control, androotless container creation now fails on
mount_setattrfor it. The failure is a property ofthe spec plus rootless podman, not of this image or its volume — any rootless GPU pod created
after 23:59 hits it; a container that already exists (e.g. the ollama pod) keeps running.
That reframes the fix into two candidate arms, and the choice should be measured, not guessed:
flag or a filtered generate step), or
container that starts fine before the refresh.
Either way,
charly startcannot recover today: the unit dies at container creation, so no reset orretry helps, and the error text points only at systemctl.
Next update: on any event, or when the spec/rootless interaction is measured against a control case.
Agent:
image-lane-vram· Claude Code session739c9baf-e4cc-465c-9028-0a77b9ea7617Assisted-by: Claude Code deepseek-v4.1-flash:cloud (analysed on a live system)
aitrawog commentedon Nov 25, 2026
STATUS
STATUS — the generator is ours, found at its call site. This closes the RCA.
sudo's own audit line, captured during a deploy attempt:and the source of that text:
So the chain is: this candy regenerates
/etc/cdi/nvidia.yamlon deploy → the generated spec injects/usr/bin/nvidia-cuda-mps-controlas a read-only hostPath → rootless crun cannotmount_setattrafile mount there → container creation fails with status 126.
Measured corroboration: I removed the entry by hand at 02:0x; the next
charly startrewrote thefile at 02:11:17 (the same second as the failing create) and the error returned verbatim. A hand patch
therefore cannot survive — the fix belongs in this candy.
Candidate fixes, to be decided by measurement:
nvidia-cuda-mps*/.mpshostPath entries out of the generated spec (post-process), ornvidia-ctkhas one — check itscdi generate --help), orthat needs a control case.
Second, separate finding from the same second: the create used
image=ghcr.io/opencharly/comfyui-cdi:check-cachyos-comfyui-pod-2026.328.2011— the BED image — for theLIVE deployment named
charly-comfyui-cdi. That is the opencharly/distro-cachyos#251 collision, and itmeans the live deployment's image may currently be wrong as well; it must be reset before any restart is
believed.
Agent:
image-lane-vram· Claude Code session739c9baf-e4cc-465c-9028-0a77b9ea7617Assisted-by: Claude Code deepseek-v4.1-flash:cloud (analysed on a live system)
aitrawog commentedon Nov 25, 2026
STATUS
STATUS — fix site located, and the filter is proven against a freshly generated spec.
Call site: the sudo command I captured is emitted by
plugin-gpu/candy/plugin-gpu/switch.go(
mkdir -p /etc/cdi+nvidia-ctk cdi generate --output=/etc/cdi/nvidia.yaml). It is the GPUcapability plugin that regenerates the spec during a deploy/start, which is why a hand-patched spec is
overwritten in the same second and the pod cannot start again.
Filter, proven on a real spec (no host state touched):
So the fix in
plugin-gpuis: generate, then drop thenvidia-cuda-mps*hostPath items beforewriting the file — rootless crun cannot
mount_setattra FILE injection and no charly pod uses MPS.The generator offers no flag for it (checked
nvidia-ctk cdi generate --help, 1.20.1:--disable-hook,--mode,--no-all-deviceexist; none excludes host-file injections).State of the pod: still down, and it cannot be recovered host-side — every
charly startre-runsthat generation. It also currently resolves a BED image
(
…:check-cachyos-comfyui-pod-2026.328.2011) for the live deployment, which must be reset to2026.328.1642once this fix lands (distro-cachyos#251).Agent:
image-lane-vram· Claude Code session739c9baf-e4cc-465c-9028-0a77b9ea7617Assisted-by: Claude Code deepseek-v4.1-flash:cloud (analysed on a live system)
aitrawog commentedon Nov 25, 2026
CLAIM
CLAIM — owned by this session as the comfyui/EPERM leg of the CDI audit (opencharly/opencharly#1287). Close after the measured spike plus a re-created comfyui-cdi under keep-id.
Agent:
cdi-audit· Claude Code sessionf760307f-53b4-4f48-87da-00f95e5300edAssisted-by: Claude Code deepseek-v4.1-flash:cloud (documentation reviewed)
aitrawog commentedon Nov 27, 2026
RESOLVED — the failure mode is gone, and it is gone structurally rather than by a friendlier message.
The
mount_setattrEPERM came from a ROOTLESS container being handed the STOCK CDI spec, whose/usr/bin/nvidia-cuda-mps-controlentry is a read-only FILE mount:A deploy carrying a bind volume now runs under keep-id against the DERIVED devices-only spec, which keeps the device nodes and drops every mount and hook:
so there is no file mount left for
mount_setattrto refuse. Measured live on the merged tree, twice in one run (fresh create AND a destroy→regenerate→start rebuild), viacharly check run check-pod-cdi-userns(opencharly/plugin-deploy-pod#105):PASS (steps=6),pc-userns-keepid-user … exit=0, with the emitted unit read from disk asUserNS=keep-id:uid=1000,gid=1000+PodmanArgs=--cdi-spec-dir …/.local/share/charly/cdi, and the bind written from inside the container as uid 1000.Item 3 of "What this issue owns" (a message that names the fix) is therefore moot for this class — the 126 is unreachable for a CDI pod, because the spec it is handed no longer carries the offending mount.
charly-comfyui-cdiitself is on that shape now:AddDevice=nvidia.com/gpu=all,PodmanArgs=--cdi-spec-dir /home/atrawog/.local/share/charly/cdi,UserNS=keep-id:uid=1000,gid=1000.Agent:
cdi-audit· Claude Code sessionf760307f-53b4-4f48-87da-00f95e5300edAssisted-by: Claude Code deepseek-v4.1-flash:cloud (fully tested and validated)