-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Podman doesn't return error when mounting rootless container with cgroups2, but mounted directory is empty. #6856
Labels
kind/bug
Categorizes issue or PR as related to a bug.
locked - please file new issue/PR
Assist humans wanting to comment on an old issue or PR with locked comments.
Comments
openshift-ci-robot
added
the
kind/bug
Categorizes issue or PR as related to a bug.
label
Jul 5, 2020
sshnaidm
added a commit
to sshnaidm/ansible-podman-collections
that referenced
this issue
Jul 5, 2020
Workaround for issue containers/podman#6856 When podman runs with CGroups v2 and rootless container, it mounts directory without error, but mounted directory is empty. Add check for the directory if it's empty.
sshnaidm
added a commit
to containers/ansible-podman-collections
that referenced
this issue
Jul 5, 2020
Workaround for issue containers/podman#6856 When podman runs with CGroups v2 and rootless container, it mounts directory without error, but mounted directory is empty. Add check for the directory if it's empty.
Probably a regression in 2.0 - |
Yeah, so can we make it failing instead of silent non-mounting? |
@baude Wrong issue 😄 |
mheon
added a commit
to mheon/libpod
that referenced
this issue
Jul 6, 2020
We require that rootless `podman mount` be run inside a shell spawned by `podman unshare` (which gives us a mount namespace which actually lets other commands use the mounted filesystem). The fix is simple - we need to mark the command as requiring the rootless user namespace not be configured, so we can test for it later as part of the mount code and error if we needed to make one. Fixes containers#6856 Signed-off-by: Matthew Heon <[email protected]>
#6868 to fix |
mheon
added a commit
to mheon/libpod
that referenced
this issue
Jul 6, 2020
We require that rootless `podman mount` be run inside a shell spawned by `podman unshare` (which gives us a mount namespace which actually lets other commands use the mounted filesystem). The fix is simple - we need to mark the command as requiring the rootless user namespace not be configured, so we can test for it later as part of the mount code and error if we needed to make one. Disable rootless tests as part of this - they were never expected to work. Fixes containers#6856 Signed-off-by: Matthew Heon <[email protected]>
skorhone
pushed a commit
to skorhone/libpod
that referenced
this issue
Jul 7, 2020
We require that rootless `podman mount` be run inside a shell spawned by `podman unshare` (which gives us a mount namespace which actually lets other commands use the mounted filesystem). The fix is simple - we need to mark the command as requiring the rootless user namespace not be configured, so we can test for it later as part of the mount code and error if we needed to make one. Fixes containers#6856 Signed-off-by: Matthew Heon <[email protected]>
github-actions
bot
added
the
locked - please file new issue/PR
Assist humans wanting to comment on an old issue or PR with locked comments.
label
Sep 23, 2023
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
kind/bug
Categorizes issue or PR as related to a bug.
locked - please file new issue/PR
Assist humans wanting to comment on an old issue or PR with locked comments.
Is this a BUG REPORT or FEATURE REQUEST? (leave only one on its own line)
/kind bug
Description
With cgroups2 when running podman rootless container, it mounts without error, but mounted directory is totally empty.
With cgroups1 the same setup shows files in mounted directory.
Currently breaks Ansible Podman connection containers/ansible-podman-collections#70
Steps to reproduce the issue:
podman container run --name pytest --detach=True python:alpine sleep 1d
ls -alsh $(podman mount pytest)
Describe the results you received:
In Ubuntu 20.04 with cgroups1:
In Fedora rawhide with cgroups2:
Describe the results you expected:
I expect mount to fail on cgroups2 rootless container and return an error exit code. Currently it pretends to mount without any error, but it's nothing in mounted directory.
Additional information you deem important (e.g. issue happens only occasionally):
Output of
podman version
:On ubuntu 20:
On Fedora rawhide:
Output of
podman info --debug
:ubuntu 20:
fedora rawhide:
Package info (e.g. output of
rpm -q podman
orapt list podman
):I'm not sure, but I think it was such error in the past. When running mount on rootless container and it didn't fail as expected.
The text was updated successfully, but these errors were encountered: