Cgroups v2 thread mode "domain invalid" state

From: Michael Kerrisk (man-pages)
Date: Wed Dec 20 2017 - 15:32:31 EST

Hello Tejun,

At some point, I'd like to add some details about cgroups v2 "thread
mode" to the cgroup(7) manual page. I think I understand most of the
details by now, but there's one question I still can't work out an
answer to: why does the "domain invalid" cgroup type exist?

I did find the July 2017 mail thread
"[PATCH 5/6] cgroup: implement cgroup v2 thread support"
where this cgroup type was discussed, but I must admit that I still
don't get it. Instead of converting cgroups under a threaded subtree
to "domain invalid" type, why can't they just be turned straight into
"threaded" type?

I guess another way of asking this question is: what possibilities
does manually switching each "domain invalid" cgroup to "threaded"
allow that wouldn't be allowed by immediately making all of the
cgroups in a threaded subtree "threaded"?



Michael Kerrisk
Linux man-pages maintainer;
Linux/UNIX System Programming Training: