You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Kernel 5.14 added support for a cgroup.kill file in cgroupv2; writing "1" to this file will immediately send SIGKILL to all processes in that cgroup hierarchy.
I have a local change to support this feature in this library but I wasn't sure which way would be the preferred method. I'm currently checking the kernel release information from uname(2) to see if the kernel version has the feature, but this is expensive (handled by a sync.Once wrapper) and I can't be sure that no-one will backport this to an older kernel (not likely but not not a possibility).
The other approach would be to just blindly send the write out and if an error is returned, just assume it's not supported and tell the caller that. An improved variant of this approach would be to have a fallback that walks the processes in the cgroup hierarchy and freezes/kills/thaws them (this is the approach used by libcontainer in runc).
The text was updated successfully, but these errors were encountered:
Kernel 5.14 added support for a
cgroup.kill
file in cgroupv2; writing "1" to this file will immediately send SIGKILL to all processes in that cgroup hierarchy.I have a local change to support this feature in this library but I wasn't sure which way would be the preferred method. I'm currently checking the kernel release information from
uname(2)
to see if the kernel version has the feature, but this is expensive (handled by a sync.Once wrapper) and I can't be sure that no-one will backport this to an older kernel (not likely but not not a possibility).The other approach would be to just blindly send the write out and if an error is returned, just assume it's not supported and tell the caller that. An improved variant of this approach would be to have a fallback that walks the processes in the cgroup hierarchy and freezes/kills/thaws them (this is the approach used by libcontainer in runc).
The text was updated successfully, but these errors were encountered: