-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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 cgroups hierarchical memory limits support #93611
Merged
janvorli
merged 7 commits into
dotnet:main
from
janvorli:enable-hierarchical-limits-support
Oct 19, 2023
Merged
Enable cgroups hierarchical memory limits support #93611
janvorli
merged 7 commits into
dotnet:main
from
janvorli:enable-hierarchical-limits-support
Oct 19, 2023
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Cgroups can limit memory hierarchically. That means that ancestor cgroups can apply limits that are lower than the current cgroup's memory limit. .NET runtime is not honoring these hierarchical limits with neither cgroups v1 nor cgroups v2. This change fixes it. The implementation is different for cgroups V1 and V2 because cgroups v1 provide aggregated hierarchical limit value in the memory.stat, but in cgroups v2, runtime needs to walk the cgroup hierarchy and find the lowest limit in it.
janvorli
commented
Oct 17, 2023
src/libraries/Common/src/Interop/Linux/cgroups/Interop.cgroups.cs
Outdated
Show resolved
Hide resolved
jkotas
reviewed
Oct 17, 2023
* Remove cgroup memory related stuff from the coreclr PAL * Real fix to the managed cgroup issue with cgroup v1 filesystem type detection
jkotas
reviewed
Oct 18, 2023
Build breaks. Lgtm otherwise. |
jkotas
approved these changes
Oct 18, 2023
This was referenced Oct 18, 2023
jkotas
reviewed
Oct 19, 2023
src/libraries/System.Runtime.InteropServices.RuntimeInformation/tests/DescriptionNameTests.cs
Outdated
Show resolved
Hide resolved
jkotas
approved these changes
Oct 19, 2023
…n/tests/DescriptionNameTests.cs Co-authored-by: Jan Kotas <[email protected]>
This broke the outerloop palsuite tests because of a removed symbol
|
Ah, I am sorry for that, Iet me fix it right away. |
PR with the fix is here: #93757 |
ghost
locked as resolved and limited conversation to collaborators
Nov 19, 2023
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Cgroups can limit memory hierarchically. That means that ancestor cgroups can apply limits that are lower than the current cgroup's memory limit. .NET runtime is not honoring these hierarchical limits with either cgroups v1 or cgroups v2.
This change fixes it. The implementation is different for cgroups V1 and V2 because cgroups v1 provide aggregated hierarchical limit value in the memory.stat, but in cgroups v2, runtime needs to walk the cgroup hierarchy and find the lowest limit in it.