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
do not touch swap for cgroup v1 if not available #119486
Conversation
This issue is currently awaiting triage. If a SIG or subproject determines this is a relevant issue, they will accept it by applying the The Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/test pull-kubernetes-e2e-ubuntu-gce-network-policies |
/test pull-kubernetes-e2e-ubuntu-gce-network-policies |
/test pull-kubernetes-e2e-ubuntu-gce-network-policies |
@pacoxu: GitHub didn't allow me to request PR reviews from the following users: iholder101. Note that only kubernetes members and repo collaborators can review this PR, and authors cannot review their own PRs. In response to this: Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/priority critical-urgent |
/test pull-kubernetes-e2e-gci-gce-ipvs |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
LGTM label has been added. Git tree hash: 468b0780371b45c7c3d6ecb6bcae9ec00f2f3cc2
|
@pacoxu Thanks for this PR, can you send your fixes in containerd repo as well? That way when they cut a new release of the containerd with your changes, we can bump it up in k8s. |
let me check the containerd fix. |
@pacoxu There is a fix in place for containerd already, containerd/containerd#8857. Please feel free to review it! |
LGTM |
/approve fixes failures in our CI jobs for a bug that certainly show up in real world scenarios as well. |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: dims, mrunalp, pacoxu The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
The fixes were backported and are available in stable releases: |
Thanks for the update.
We may bump containerd later. |
// Some swapping is still possible. | ||
// Note that if memory limit is 0, memory swap limit is ignored. | ||
lcr.MemorySwapLimitInBytes = lcr.MemoryLimitInBytes | ||
if swapControllerAvailable() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Question: Should this not be checked regardless of whether unified mode is enabled. Otherwise we explicitly set memory.swap.max
even if swap is disabled?
For reference, I am having issues launching a >= 1.28.0 using kind
on a node where swap is disabled. (I will spend some time creating an issue tomorrow).
cc @iholder101
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this fix a problem? I cannot catch up with you here.
This added a check for no-cgroup v2
: to not set swap if swap controller is not available.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this fix is fine. I was asking whether this check should also be done on cgroup v2
systems. I have a PR #120784 under review to do this -- effectively moving the check higher up the call chain.
Feel free to review this as well.
What type of PR is this?
/kind bug
What this PR does / why we need it:
Which issue(s) this PR fixes:
Fixes #119467 #119446
Special notes for your reviewer:
Does this PR introduce a user-facing change?