<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri","sans-serif";}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal>Hi,<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I am trying to start a lxc container I have setup on a test Centos 6.4 box. I downloaded and built lxc-0.9.0 <o:p></o:p></p><p class=MsoNormal>and installed it into /opt/lxc-0.9.0. I believe I have it setup properly and my test lxc host is called host1.<o:p></o:p></p><p class=MsoNormal>When I try to start it I get:<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>[root@sandbox ~]# lxc-start -n host1<o:p></o:p></p><p class=MsoNormal>lxc-start: Error creating cgroups<o:p></o:p></p><p class=MsoNormal>lxc-start: failed to spawn 'host1'<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I have /cgroup mounted:<o:p></o:p></p><p class=MsoNormal>[root@sandbox ~]# mount |grep cgroup<o:p></o:p></p><p class=MsoNormal>cgroup on /cgroup type cgroup (rw)<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>[root@sandbox ~]# cat /proc/mounts | grep cgroup<o:p></o:p></p><p class=MsoNormal>cgroup /cgroup cgroup rw,relatime,net_prio,perf_event,blkio,net_cls,freezer,devices,memory,cpuacct,cpu,ns,cpuset 0 0<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I did a strace with the start command and it seems it can’t execute mkdir:<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>access("/cgroup/lxc/host1", F_OK)       = -1 ENOENT (No such file or directory)<o:p></o:p></p><p class=MsoNormal>mkdir("/cgroup/lxc/host1", 0755)        = -1 EINVAL (Invalid argument)<o:p></o:p></p><p class=MsoNormal>write(3, "      lxc-start 1375881857.425 E"..., 76) = 76<o:p></o:p></p><p class=MsoNormal>write(2, "lxc-start: ", 11lxc-start: )             = 11<o:p></o:p></p><p class=MsoNormal>write(2, "Error creating cgroups", 22Error creating cgroups)  = 22<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Sure enough, I can’t create a dir below the lxc level, but I can at the lxc level:<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>[root@sandbox ~]# mkdir /cgroup/lxc/host1<o:p></o:p></p><p class=MsoNormal>mkdir: cannot create directory `/cgroup/lxc/host1': Invalid argument<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>[root@sandbox ~]# mkdir /cgroup/foo<o:p></o:p></p><p class=MsoNormal>[root@sandbox ~]# rmdir /cgroup/foo<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>[root@sandbox ~]# uname -a<o:p></o:p></p><p class=MsoNormal>Linux sandbox.rc.fas.harvard.edu 2.6.32-358.11.1.el6.x86_64 #1 SMP Wed Jun 12 03:34:52 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux<o:p></o:p></p><p class=MsoNormal>[root@sandbox ~]# more /etc/issue<o:p></o:p></p><p class=MsoNormal>CentOS release 6.4 (Final)<o:p></o:p></p><p class=MsoNormal>Kernel \r on an \m<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Any ideas why this is happening and how to fix it ?<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Thanks in advance,<o:p></o:p></p><p class=MsoNormal>Mike<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal><o:p> </o:p></p></div></body></html>