diff --git a/man7/cgroups.7 b/man7/cgroups.7 index 2f945c3de..a57652d2e 100644 --- a/man7/cgroups.7 +++ b/man7/cgroups.7 @@ -797,6 +797,42 @@ before being destroyed. A process can't be made a member of a dying cgroup, and a dying cgroup can't be brought back to life. .\" +.SS Limiting the number of descendant cgroups +Each cgroup in the v2 hierarchy contains the following files, +which can be used to view and set limits on the number +of descendant cgroups under that cgroup: +.TP +.IR cgroup.max.depth " (since Linux 4.14)" +.\" commit 1a926e0bbab83bae8207d05a533173425e0496d1 +This file defines a limit on the depth of nesting of descendant cgroups. +A value of 0 in this file means that no descendant cgroups can be created. +An attempt to create a descendant whose nesting level exceeds +the limit fails +.RI ( mkdir (2) +fails with the error +.BR EAGAIN ). +.IP +Writing the string +.IR """max""" +to this file means that no limit is imposed. +The default value in this file is +.IR """max""" . +.TP +.IR cgroup.max.descendants " (since Linux 4.14)" +.\" commit 1a926e0bbab83bae8207d05a533173425e0496d1 +This file defines a limit on the number of live descendant cgroups that +this cgroup may have. +An attempt to create more descendants than allowed by the limit fails +.RI ( mkdir (2) +fails with the error +.BR EAGAIN ). +.IP +Writing the string +.IR """max""" +to this file means that no limit is imposed. +The default value in this file is +.IR """max""" . +.\" .SS Cgroups v2 delegation In the context of cgroups, delegation means passing management of some subtree