[cgmanager-devel] /sys/fs/cgroup/cgmanager does not exist in a container

Serge Hallyn serge.hallyn at ubuntu.com
Sun Mar 30 23:10:51 UTC 2014


Quoting Andy Johnson (johnsonzjo at gmail.com):
> Hi,
> 
> >How did you create the container?
> > If using lxc-create+lxc-start
> Yes.
> 
> >then you need to add the line
> > lxc.mount.auto = cgroup
> 
> This did not help.
> >Alternatively you can do
> 
> >lxc.mount.entry = sys/fs/cgroup/cgmanager /sys/fs/cgroup/cgmanager \
> >        none bind,create=dir 0 0
> 
> 
> I assume you mean: (note the slash before sys on the right side)
> lxc.mount.entry = /sys/fs/cgroup/cgmanager

Yeah, I meant a slahs before the first and *not* before the second
path.

> This did not help either. I tried both in Ubuntu and Fedora.
> I would appreciate if in some documentation file/wiki/your blog or

There is documentation at

https://help.ubuntu.com/14.04/serverguide/cgroups.html

> anywhere else, it will be explained, step by step, how to use the
> cgmanager on a container created with lxc-create and lxc-start

I'll make a blog post tonight or tomorrow showing how to do nested
lxc with cgmanager, then I'll put some howto onto the
cgmanager.linuxcontainers.org page.

> regards,
> Andy
> 
> 
> 
> 
> On Sat, Mar 29, 2014 at 6:15 PM, Serge Hallyn <serge.hallyn at ubuntu.com> wrote:
> > Quoting Andy Johnson (johnsonzjo at gmail.com):
> >> Hello,
> >> I know that from containers you should better use cgproxy.
> >> I was just wondering:
> >> In a host I run cgmanager (taken from most recent git)
> >> Now, I have on the host
> >> /sys/fs/cgroup/cgmanager/
> >> and also /sys/fs/cgroup/cgmanager/sock
> >> I start a container from the host (Fedora container)
> >> I do not see /sys/fs/cgroup/cgmanager/ and /sys/fs/cgroup/cgmanager/sock
> >
> > How did you create the container?  If using lxc-create+lxc-start,
> > then you need to add the line
> >
> > lxc.mount.auto = cgroup
> >
> > to the container configuration file.  Alternatively you can do
> >
> > lxc.mount.entry = sys/fs/cgroup/cgmanager /sys/fs/cgroup/cgmanager \
> >         none bind,create=dir 0 0
> >
> >> What, in fact, is the reason for this ? I see by running "mount" from
> >> the container that /sys/fs/cgroup is mounted as rw:
> >>
> >> mount | grep  /sys/fs/cgroup
> >> ...
> >> tmpfs on /sys/fs/cgroup type tmpfs (rw,nosuid,nodev,noexec,mode=755
> >> ...
> >>
> >> And the container is created and run as root from the host.
> >> regards,
> >> Andy
> >> _______________________________________________
> >> cgmanager-devel mailing list
> >> cgmanager-devel at lists.linuxcontainers.org
> >> http://lists.linuxcontainers.org/listinfo/cgmanager-devel
> > _______________________________________________
> > cgmanager-devel mailing list
> > cgmanager-devel at lists.linuxcontainers.org
> > http://lists.linuxcontainers.org/listinfo/cgmanager-devel
> _______________________________________________
> cgmanager-devel mailing list
> cgmanager-devel at lists.linuxcontainers.org
> http://lists.linuxcontainers.org/listinfo/cgmanager-devel


More information about the cgmanager-devel mailing list