<div dir="ltr"><p dir="ltr"><br>
On Sep 11, 2015 18:46, "Cyrill Gorcunov" <<a href="mailto:gorcunov@gmail.com" target="_blank">gorcunov@gmail.com</a>> wrote:<br>
><br>
> On Fri, Sep 11, 2015 at 06:35:46PM +0300, Andrey Vagin wrote:<br>
> > Some controllers can be disabled in kernel options. In this case they<br>
> > are shown in /proc/cgroups, but they could not be mounted.<br>
> ><br>
> > All enabled controllers can be collected from /proc/self/cgroup.<br>
> ><br>
> > <a href="https://github.com/xemul/criu/issues/28" target="_blank">https://github.com/xemul/criu/issues/28</a><br>
> ><br>
> > v2: ',' is used to separate controllers<br>
> ><br>
> > Cc: Tycho Andersen <<a href="mailto:tycho.andersen@canonical.com" target="_blank">tycho.andersen@canonical.com</a>><br>
> > Reported-by: Ross Boucher <<a href="mailto:boucher@gmail.com" target="_blank">boucher@gmail.com</a>><br>
> > Signed-off-by: Andrey Vagin <<a href="mailto:avagin@openvz.org" target="_blank">avagin@openvz.org</a>><br>
> ><br>
><br>
> Could you please explain why can't you test the "active"<br>
> field from /proc/cgroups and simply skip the controller<br>
> if it's disabled?</p><p>There is the "enabled" field? Don't know, haven't heard;)</p><p>Seriously, the old version looks up a hierarchy for each controller.</p><p>In this version we get all controllers together, so the complexity of the current version is O(n) instead of O(n^2)</p>
</div>