Rootless Container Image Unpacking Fails With EACCESS
I maintainer di solito rispondono entro 2 giorni
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 43/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Attiva
- Stack tecnologico
- rust
- Ambito
- infrastructure
Direzione di ricerca
Start by reproducing the nested rootless podman pull failure with the provided podman/krun command, then compare behavior when the graph root is on virtiofs versus tmpfs. The issue names no repository files or tests, so first trace how libkrun handles virtiofs permissions during layer unpacking. Done means identifying whether libkrun causes the EACCES and documenting or fixing the confirmed cause.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
I was trying to run rootless podman inside a podman + krun guest, but was unable to podman pull images. They would fail with:
Error: copying system image from manifest list: writing blob: adding layer with blob "sha256:55afa1ecc21d2bb5e5045f32dafee56272ffd89860bac26f6c32123439af26a4"/""/"sha256:34884abbe92863fce933ed7c39c0e045631af0ed86d5cc0dfbdf9fdca426ce3c": unpacking failed (error: exit status 1; output: setting up pivot dir: mkdir ./.pivot_root4119440341: permission denied
With EACCESS; from strace:
[pid 1373] mkdirat(AT_FDCWD, "/home/nlordell/.local/share/containers/storage/overlay/34884abbe92863fce933ed7c39c0e045631af0ed86d5cc0dfbdf9fdca426ce3c/diff", 0555) = 0
...
[pid 1378] mkdirat(AT_FDCWD, "./.pivot_root1142747937", 0700) = -1 EACCES (Permission denied)
A minimal reproducer assuming podman and crun-krun on the host:
podman run --runtime=krun -it --rm debian:13 bash -c "
apt-get update && apt-get install -y podman
podman pull alpine # works
useradd -m -U myuser
su -c 'podman pull alpine' - myuser # fails
"
It appears to be an issue with using a podman graph-root on a virtiofs filesystem as an unprivileged user. If I use, for example, --root /dev/shm/... (which is tmpfs) then everything works.
As a workaround, I was able to loop-mount a disk image in the container itself to get podman to work:
sudo truncate -s 20G /var/lib/podman-storage.img
sudo mkfs.ext4 /var/lib/podman-storage.img
sudo mkdir -p /mnt/podman-storage
sudo mount -o loop /var/lib/podman-storage.img /mnt/podman-storage
sudo install -d -o myuser -g myuser /mnt/podman-storage/container
podman pull --root /mnt/podman-storage/container alpine
In chatting with an LLM, it told be very confidently that:
The
overlayandvfsdrivers create the layer's diff directory mode0555and rely onCAP_DAC_OVERRIDEto write into it. Capabilities are not part of the FUSE protocol — a request carries only uid/gid — so the FUSE server re-evaluates the DAC check as the unprivileged uid and denies the write.
But do not have the know-how or understanding to evaluate whether or not it is accurate. Including it here in case it helps narrow down the issue. I am also not sure whether or not this is actually a libkrun issue, and I really don't have much understanding about how the whole podman, crun, libkrun interact, but looking through the issues in this repo it felt like it was a reasonable place to report it (as it appears to be a virtiofs related issue). Please let me know if I should move this issue elsewhere.
- Lingua principale
- Rust
- Stelle
- 2.8k
- Fork
- 279
- Merge medio
- 3g 17h
- PR unite (30g)
- 22
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di libkrun/libkrun
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
libkrun/libkrun#895 · 2 commenti ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 8/100
libkrun/libkrun#929 · 1 commento ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 12/100
libkrun/libkrun#926 · 1 commento ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 15/100
libkrun/libkrun#924 · 1 commento ·
I maintainer di solito rispondono entro 2 giorni
Tutte le issue di libkrun/libkrun
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
home-assistant/installer#308 ·
I maintainer di solito rispondono entro 1 giorno
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
swc-project/swc-next#1053 ·
I maintainer di solito rispondono entro 1 giorno
-
What happened to `check.py`?Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 67/100
linebender/resvg#1179 · 1 commento ·
I maintainer di solito rispondono entro 2 giorni
-
enhancement triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
zizmorcore/zizmor#2468 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 64/100
I maintainer di solito rispondono entro 2 giorni