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

Linux Control Group version 2 API support (cgroup v2) #1262

Open
tim-seoss opened this issue Jul 14, 2022 · 3 comments
Open

Linux Control Group version 2 API support (cgroup v2) #1262

tim-seoss opened this issue Jul 14, 2022 · 3 comments
Labels
enhancement New feature or request

Comments

@tim-seoss
Copy link

Feature Description
Support Linux Control Group Version 2 API

Use Case
Greengrass is the last software component I work with, that doesn't yet have cgroup v2 support. The two APIs are mutually incompatible and since v2 support is widespread, it's now likely that persisting with the v1 API will become troublesome for users (because other userspace components which rely on the v2 API cannot be used at the same time as greengrass).

Proposed Solution
The presence of cgroup v2 controllers could be detected at runtime, and the newer API used if available.

@tim-seoss tim-seoss added the needs-triage Needs eyeballs label Jul 14, 2022
@MikeDombo
Copy link
Member

Hello Tim,
Thank you for the request. Are you talking about Greengrass V2 Lambda's usage of cgroup? Or about Greengrass Nucleus itself https://github.com/aws-greengrass/aws-greengrass-nucleus/blob/c2f07307b83f53c4e3d7f46451016b1bdd44cef2/src/main/java/com/aws/greengrass/util/platforms/unix/linux/LinuxSystemResourceController.java?

@MikeDombo MikeDombo added enhancement New feature or request and removed needs-triage Needs eyeballs labels Jul 14, 2022
@tim-seoss
Copy link
Author

I think both will need to get cgroup2 support. Most distros are now defaulting to cgroup2. Some software which end-users will want to deploy will require cgroup2-only functionality, and in the areas of their APIs where cgroup v1 and cgroup v2 cannot both be made available on the same machine, then cgroup v2 will need to be used in order for the greengrass components to be usable with these other software components.

"An introduction to control groups (cgroups) version 2 - Michael Kerrisk - NDC TechTown 2021" (and the accompanying deep dive talk) provides a good overview of the state of support and defaults as of late last year. In the medium term, cgroup v1 will become less and less well supported, with new software only support cgroup v2, and cgroup v1 support will become more and more awkward.

@MikeDombo
Copy link
Member

Thanks, I understand. Just trying to understand your specific use case @tim-seoss. What error are you hitting specifically?

ChangxinDong added a commit to ChangxinDong/aws-greengrass-nucleus-1048 that referenced this issue Sep 30, 2022
ChangxinDong added a commit to ChangxinDong/aws-greengrass-nucleus-1048 that referenced this issue Oct 8, 2022
ChangxinDong added a commit to ChangxinDong/aws-greengrass-nucleus-1048 that referenced this issue Oct 9, 2022
ChangxinDong added a commit to ChangxinDong/aws-greengrass-nucleus-1048 that referenced this issue Oct 9, 2022
yiwenTS added a commit to ChangxinDong/aws-greengrass-nucleus-1048 that referenced this issue Oct 10, 2022
ChangxinDong added a commit to ChangxinDong/aws-greengrass-nucleus-1048 that referenced this issue Oct 10, 2022
ChangxinDong added a commit to ChangxinDong/aws-greengrass-nucleus-1048 that referenced this issue Oct 10, 2022
ChangxinDong added a commit to ChangxinDong/aws-greengrass-nucleus-1048 that referenced this issue Oct 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants