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

Don't support cgroupns on cgroups v1 #4308

Merged
merged 2 commits into from
Oct 13, 2023
Merged

Conversation

mook-as
Copy link
Contributor

@mook-as mook-as commented Oct 4, 2023

Possibly fixes #4108.

Note that I have no idea what I'm doing; I'm basing the new stat call on what the tests in #4003 are doing (on the assumption that if it is not compatible with the test, it was probably what broke my use cases too). Any suggestions on what to do instead (or even just PRs that replace this one) very welcome.

Fixes moby#4108

Signed-off-by: Mark Yen <mark.yen@suse.com>
@@ -150,9 +150,13 @@ func getTracingSocket() string {

func cgroupNamespaceSupported() bool {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
func cgroupNamespaceSupported() bool {
func cgroupV2NamespaceSupported() bool {

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also please add comment lines to explain the background for this

mook-as added a commit to mook-as/buildkit that referenced this pull request Oct 4, 2023
This responds to review feedback from
moby#4308 (review)

Signed-off-by: Mark Yen <mark.yen@suse.com>
func cgroupV2NamespaceSupported() bool {
// Check if cgroups v2 namespaces are supported. Trying to do cgroup
// namespaces with cgroups v1 results in EINVAL when we encounter a
// non-standard hierarchy.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Needs a link to the issue ticket

This responds to review feedback from
moby#4308 (review)

Signed-off-by: Mark Yen <mark.yen@suse.com>
@AkihiroSuda
Copy link
Member

I think we can merge this but we would still like to see the original issue to be analyzed properly

@tonistiigi
Copy link
Member

I think we can merge this but we would still like to see the original issue to be analyzed properly

This was added in #4003 and released in v0.12 that should be the regression point.

@jedevc jedevc merged commit 0b13071 into moby:master Oct 13, 2023
55 of 57 checks passed
jedevc pushed a commit to jedevc/buildkit that referenced this pull request Oct 13, 2023
This responds to review feedback from
moby#4308 (review)

Signed-off-by: Mark Yen <mark.yen@suse.com>
(cherry picked from commit f9ccb09)
Signed-off-by: Justin Chadwell <me@jedevc.com>
@mook-as mook-as deleted the 4108-alpine-cgroups branch October 16, 2023 20:23
nxmatic pushed a commit to nxmatic/buildkit that referenced this pull request Dec 3, 2023
This responds to review feedback from
moby#4308 (review)

Signed-off-by: Mark Yen <mark.yen@suse.com>
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 this pull request may close these issues.

[potential regression in v0.12] unable to start container on /sys/fs/cgroup/* mount
5 participants