Skip to content
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

Enable cgroup namespace by default for container #3734

Open
dqminh opened this issue Nov 16, 2021 · 0 comments · May be fixed by #3735
Open

Enable cgroup namespace by default for container #3734

dqminh opened this issue Nov 16, 2021 · 0 comments · May be fixed by #3735

Comments

@dqminh
Copy link

dqminh commented Nov 16, 2021

Currently, container is run without cgroup namespace, which creates non-functioning setup with cgroupv2 when cgroupv2 restrictions are enforced.

For example, the cgroup tree for docker without cgroup namespace is:

/sys/fs/cgroup/
   docker/: <--- dockerd lives here. 
       containerA: <--- containerA lives here. 

As a result, /sys/fs/cgroup/docker becomes domain threaded cgroup, and cgroup manipulation within containerA doesn't work properly.

I think it should be safe to enable creation of cgroup namespace by default, or at least when we are running under cgroupv2.

dqminh added a commit to dqminh/linuxkit that referenced this issue Nov 16, 2021
In cgroupv2 hierrachy, cgroup setup for nested containers (i.e. docker)
are incorrect without enabling cgroup namespace. This enables cgroup
namespace for all containers to fix the incorrect cgroup setup.

See linuxkit#3734

Signed-off-by: Daniel Dao <dqminh89@gmail.com>
@dqminh dqminh linked a pull request Nov 16, 2021 that will close this issue
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 a pull request may close this issue.

1 participant