cgroups
cgroups copied to clipboard
dont ignore failure to create cgroup after timeout
I noticed that creating a cgroup will silently ignore timeouts and continue on. Concretely, I've hit cases where a cgroup fails to get created, and the caller ends up looking for cgroups.controllers only to find it isn't there.
It's very difficult as a caller to deal with this case, where NewSystemd succeeds but the group doesn't exist.
I traced the origins of this code to https://github.com/containerd/cgroups/commit/5efa14e3dbc5c34d93de6c706af24fea4a30de46#diff-3331981e4ac06a8d9b06e91842b7f2759c7af3b65287e489a88385948d311ebdR672 - which was written 5+ years ago.
runc added roughly the same logic here: https://github.com/opencontainers/runc/pull/3782
Looks good, but can you squash the commits and write the same blurb you have in the PR description in the commit message? Thanks!
Looks good, but can you squash the commits and write the same blurb you have in the PR description in the commit message? Thanks!
Done!
@dcantah what's the path to getting this merged?
@jchorl Just needs another approval, I'll shop this around to folks