]> git.ipfire.org Git - thirdparty/lxc.git/commit
support use of 'all' containers when cgmanager supports it
authorSerge Hallyn <serge.hallyn@ubuntu.com>
Thu, 18 Sep 2014 21:20:02 +0000 (21:20 +0000)
committerStéphane Graber <stgraber@ubuntu.com>
Sat, 20 Sep 2014 01:21:01 +0000 (21:21 -0400)
commit69a8b71ba5b8900d5b8a1784061c72f995acacb6
tree0a1baf6e3007229cca9826e982514c23e575d531
parent6d0bd79370f7d5758173f8928ae5599b0f9dc0d2
support use of 'all' containers when cgmanager supports it

Introduce a new list of controllers just containing "all".

Make the lists of controllers null-terminated.

If the cgmanager api version is high enough, use the 'all' controller
rather than walking all controllers, which should greatly reduce the
amount of dbus overhead.  This will be especially important for
those going through a cgproxy.

Also remove the call to cleanup cgroups when a cgroup existed.  That
usually fails (and failure is ignored) since the to-be-cleaned-up
cgroup is busy, but we shouldn't even be trying.  Note this can
create for extra un-cleanedup cgroups, however it's better than us
accidentally removing a cgroup that someone else had created and was
about to use.

Signed-off-by: Serge Hallyn <serge.hallyn@ubuntu.com>
Acked-by: Stéphane Graber <stgraber@ubuntu.com>
src/lxc/cgmanager.c