[lxc-devel] Containers do not start with lxc-1.0.0.beta2 on RHEL-6.5
Robert Vogelgesang
vogel at users.sourceforge.net
Mon Jan 20 11:16:35 UTC 2014
Hello Serge,
thank you for your clear explanation.
On Fri, Jan 17, 2014 at 04:21:49PM -0600, Serge Hallyn wrote:
[...]
> When you're not allowed to set clone_children, it is likely because
> there are already other child cgroups. You cannot change clone_children
> in that case.
Sorry, no, this is not the case, there are no child cgroups.
I've done some more "research", and as it seems, the current RHEL-6
kernel, kernel-2.6.32-431.3.1.el6.x86_64, does not support the
cgroup.clone_children flag. With this kernel, the /cgroup/cpuset/
directory does not contain a cgroup.clone_children file, and creating
it fails no matter how I try it. If I read the kernel sources
correctly, the clone_children flag was introduced with kernel-2.6.37,
and Redhat didn't backport it to the RHEL-6 kernel.
>
> When you get -ENOSPC it is because clone_children was not set, so the
> cpuset.mems and cpuset.cpus files were not initialized in the
> container's cgroups. (I've always hated this behavior).
By using strace I've seen that lxc-start from lxc-0.9.0 simply ignores
the errors when setting cgroup.clone_children and this one when trying
to move the container into the cpuset cgroup; with lxc-0.9.0,
/cgroup/cpuset/lxc/test/tasks exists, but is empty.
Does this mean that with RHEL-6 one cannot use a cpuset cgroup, at
least not with lxc? If so, is there a simple way I could tell the
lxc tools to leave it alone, even if it exists (i.e. is mounted)?
>
> The *surest* way to avoid problems is to set up an early init job for
> yourself which sets clone_children to 1 in the root cpuset cgroup.
As I said above, I failed to set clone_children with the RHEL-6 kernel.
Is there some special trick or tool I must use to achieve this?
Robert
More information about the lxc-devel
mailing list