diff options
author | Austin S. Hemmelgarn <ahferroin7@gmail.com> | 2015-10-06 15:02:28 -0500 |
---|---|---|
committer | William Hubbs <w.d.hubbs@gmail.com> | 2015-10-06 15:05:35 -0500 |
commit | 80d3928b0d13f09a9c1e82bd27c9fff943d84d43 (patch) | |
tree | 6d1db64353e5a004ba0d72735b86a73da3afbd65 /sh/rc-cgroup.sh.in | |
parent | 17ef205bc63a4e231dccee719394a7a8563f8c3f (diff) |
cgroups: Add the hugetlb, net_cls and pids controllers
Note from WilliamH: I slightly rearranged the code and added the
settings in rc.conf.
X-Gentoo-Bug: 555488
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=555488
Diffstat (limited to 'sh/rc-cgroup.sh.in')
-rw-r--r-- | sh/rc-cgroup.sh.in | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/sh/rc-cgroup.sh.in b/sh/rc-cgroup.sh.in index 3f34d179..b49c7115 100644 --- a/sh/rc-cgroup.sh.in +++ b/sh/rc-cgroup.sh.in @@ -109,12 +109,21 @@ cgroup_set_limits() local devices="${rc_cgroup_devices:-$RC_CGROUP_DEVICES}" [ -n "$devices" ] && cgroup_set_values devices "$devices" + local hugetlb="${rc_cgroup_hugetlb:-$RC_CGROUP_HUGETLB}" + [ -n "$hugetlb" ] && cgroup_set_values hugetlb "$hugetlb" + local memory="${rc_cgroup_memory:-$RC_CGROUP_MEMORY}" [ -n "$memory" ] && cgroup_set_values memory "$memory" + local net_cls="${rc_cgroup_net_cls:-$RC_CGROUP_NET_CLS}" + [ -n "$net_cls" ] && cgroup_set_values net_cls "$net_cls" + local net_prio="${rc_cgroup_net_prio:-$RC_CGROUP_NET_PRIO}" [ -n "$net_prio" ] && cgroup_set_values net_prio "$net_prio" + local pids="${rc_cgroup_pids:-$RC_CGROUP_PIDS}" + [ -n "$pids" ] && cgroup_set_values pids "$pids" + return 0 } |