[Lxc-users] lxc on Fedora 15

Ramez Hanna rhanna at informatiq.org
Tue May 31 10:33:21 UTC 2011


it seems that lxc cannot handle cgroups when capabilities are not all in the
same mount
it fails now because it cannot write the devices.deny in the cgroup
if i comment out all the lxc.cgroup.devices lines in the config of the
container then i can actually start it

I would think that the way lxc identifies the cgroup mount might be the part
that needs patching



On Tue, May 31, 2011 at 11:00 AM, Ramez Hanna <rhanna at informatiq.org> wrote:

> On Sat, May 28, 2011 at 3:33 PM, Ramez Hanna <rhanna at informatiq.org>wrote:
>
>> I have failed to start a container on f15 although it worked fine on 14
>> here is the log
>> ==snip
>> [root at hovercraft boss]# cat lxc.log
>> lxc-start 1306584262.160 DEBUG lxc_conf - allocated pty '/dev/pts/9' (4/5)
>> lxc-start 1306584262.160 DEBUG lxc_conf - allocated pty '/dev/pts/10'
>> (6/7)
>> lxc-start 1306584262.160 DEBUG lxc_conf - allocated pty '/dev/pts/11'
>> (8/9)
>> lxc-start 1306584262.160 DEBUG lxc_conf - allocated pty '/dev/pts/12'
>> (10/11)
>> lxc-start 1306584262.160 INFO lxc_conf - tty's configured
>> lxc-start 1306584262.160 ERROR lxc_caps - failed to cap_get_flag: Invalid
>> argument
>> lxc-start 1306584262.160 DEBUG lxc_console - using '/dev/tty' as console
>> lxc-start 1306584262.160 DEBUG lxc_start - sigchild handler set
>> lxc-start 1306584262.161 INFO lxc_start - 'boss' is initialized
>> lxc-start 1306584262.161 ERROR lxc_namespace - failed to
>> clone(0x6c020000): Operation not permitted
>> lxc-start 1306584262.161 ERROR lxc_start - Operation not permitted -
>> failed to fork into a new namespace
>> lxc-start 1306584262.161 ERROR lxc_start - failed to spawn 'boss'
>> lxc-start 1306584262.161 DEBUG lxc_cgroup - using cgroup mounted at
>> '/sys/fs/cgroup/systemd'
>> lxc-start 1306584262.161 ERROR lxc_cgroup - No such file or directory -
>> failed to remove cgroup '/sys/fs/cgroup/systemd/boss'
>> == end
>>
>> mounts
>> [root at hovercraft boss]# mount |grep cgroup
>> tmpfs on /sys/fs/cgroup type tmpfs
>> (rw,nosuid,nodev,noexec,relatime,mode=755)
>> cgroup on /sys/fs/cgroup/systemd type cgroup
>> (rw,nosuid,nodev,noexec,relatime,release_agent=/lib/systemd/systemd-cgroups-agent,name=systemd)
>> cgroup on /sys/fs/cgroup/cpuset type cgroup
>> (rw,nosuid,nodev,noexec,relatime,cpuset)
>> cgroup on /sys/fs/cgroup/ns type cgroup
>> (rw,nosuid,nodev,noexec,relatime,ns)
>> cgroup on /sys/fs/cgroup/cpu type cgroup
>> (rw,nosuid,nodev,noexec,relatime,cpu)
>> cgroup on /sys/fs/cgroup/cpuacct type cgroup
>> (rw,nosuid,nodev,noexec,relatime,cpuacct)
>> cgroup on /sys/fs/cgroup/memory type cgroup
>> (rw,nosuid,nodev,noexec,relatime,memory)
>> cgroup on /sys/fs/cgroup/devices type cgroup
>> (rw,nosuid,nodev,noexec,relatime,devices)
>> cgroup on /sys/fs/cgroup/freezer type cgroup
>> (rw,nosuid,nodev,noexec,relatime,freezer)
>> cgroup on /sys/fs/cgroup/net_cls type cgroup
>> (rw,nosuid,nodev,noexec,relatime,net_cls)
>> cgroup on /sys/fs/cgroup/blkio type cgroup
>> (rw,nosuid,nodev,noexec,relatime,blkio)
>>
>> it looks like lxc is trying to create the container's cgroup under systemd
>> which seems to be the wrong location
>> any leads on how can i debug further
>> how does lxc find where cgroup is mounted?
>>
>> see bug https://bugzilla.redhat.com/show_bug.cgi?id=683667
>>
>
>
> upgraded to lxc-0.7.4.1-1.1.x86_64
>
> [root at hovercraft ~]# lxc-start -n boss -l DEBUG -o log
> lxc-start: open /sys/fs/cgroup/systemd/boss/devices.deny : No such file or
> directory
> lxc-start: failed to setup the cgroups for 'boss'
> lxc-start: failed to setup the container
> lxc-start: invalid sequence number 1. expected 2
>
> lxc-start: failed to spawn 'boss'
>
> [root at hovercraft ~]# cat log
> lxc-start 1306828803.471 DEBUG lxc_conf - allocated pty '/dev/pts/9' (4/5)
> lxc-start 1306828803.471 DEBUG lxc_conf - allocated pty '/dev/pts/10' (6/7)
> lxc-start 1306828803.471 DEBUG lxc_conf - allocated pty '/dev/pts/11' (8/9)
> lxc-start 1306828803.471 DEBUG lxc_conf - allocated pty '/dev/pts/12'
> (10/11)
> lxc-start 1306828803.471 INFO lxc_conf - tty's configured
> lxc-start 1306828803.471 DEBUG lxc_console - using '/dev/tty' as console
> lxc-start 1306828803.471 DEBUG lxc_start - sigchild handler set
> lxc-start 1306828803.471 INFO lxc_start - 'boss' is initialized
> lxc-start 1306828803.478 DEBUG lxc_cgroup - using cgroup mounted at
> '/sys/fs/cgroup/systemd'
> lxc-start 1306828803.479 DEBUG lxc_cgroup - cgroup flags is 0x2
> lxc-start 1306828803.485 INFO lxc_conf - network has been setup
> lxc-start 1306828803.485 DEBUG lxc_conf - mounted
> '/var/lib/lxc/boss/rootfs' on '/usr/lib64/lxc/rootfs'
> lxc-start 1306828803.485 DEBUG lxc_conf - mounted 'proc' on
> '/usr/lib64/lxc/rootfs//proc', type 'proc'
> lxc-start 1306828803.486 DEBUG lxc_conf - mounted 'devpts' on
> '/usr/lib64/lxc/rootfs//dev/pts', type 'devpts'
> lxc-start 1306828803.486 DEBUG lxc_conf - mounted 'sysfs' on
> '/usr/lib64/lxc/rootfs//sys', type 'sysfs'
> lxc-start 1306828803.486 INFO lxc_conf - mount points have been setup
> lxc-start 1306828803.486 DEBUG lxc_cgroup - using cgroup mounted at
> '/sys/fs/cgroup/systemd'
> lxc-start 1306828803.486 ERROR lxc_cgroup - open
> /sys/fs/cgroup/systemd/boss/devices.deny : No such file or directory
> lxc-start 1306828803.486 ERROR lxc_conf - failed to setup the cgroups for
> 'boss'
> lxc-start 1306828803.486 ERROR lxc_start - failed to setup the container
> lxc-start 1306828803.486 ERROR lxc_sync - invalid sequence number 1.
> expected 2
> lxc-start 1306828803.486 ERROR lxc_start - failed to spawn 'boss'
> lxc-start 1306828803.486 DEBUG lxc_cgroup - using cgroup mounted at
> '/sys/fs/cgroup/systemd'
> lxc-start 1306828803.491 DEBUG lxc_cgroup - '/sys/fs/cgroup/systemd/boss'
> unlinked
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20110531/f53b7ec2/attachment.html>


More information about the lxc-users mailing list