If I understand the lxc code right, it's failing in the function
get_cgroup_mount in src/lxc/cgroup.c, which tries to read the cgroup mount
point from /proc/mounts.
/proc/mount seems to be fine on my machine:
$ cat /proc/mounts
...
...
cgroup /cgroup cgroup
rw,relatime,blkio,net_cls,freezer,devices,memory,cpuacct,cpu,debug,cpuset,clone_children
0 0
The cgroup entry is present, but it seems it's unable to open /proc/mounts.
-/\/
On Thu, Sep 8, 2011 at 1:16 PM, Nikhil Handigol
<[email protected]>wrote:
> Ah! That was something I had missed. I recompiled lxc with
> the --with-linuxdir option and the old error went away.
>
> Now I'm getting the following error:
> $ lxc-attach -n foo -- /bin/bash
> lxc-attach: No such file or directory - failed to open /proc/mounts
> lxc-attach: cgroup is not mounted
> lxc-attach: No such file or directory - failed to get cgroup path for
> cgroup foo
>
> On my machine, cgroup is mounted on /cgroup via the following command:
> mount -t cgroup cgroup /cgroup
>
> It looks like I also need to specify where cgroup is mounted? How do I do
> that?
> (I think we're close to getting this to work)
>
> Thanks,
> -/\/
>
>
>
> On Thu, Sep 8, 2011 at 1:07 PM, Daniel Lezcano <[email protected]>wrote:
>
>> On 09/08/2011 07:12 PM, Nikhil Handigol wrote:
>> > It is indeed the case:
>> >
>> > $ type lxc-attach
>> > lxc-attach is /usr/local/bin/lxc-attach
>>
>> Ok.
>>
>> Did you specified the kernel source tree when invoking configure ?
>>
>> It is the --with-linuxdir=<path_to_the_patched_kernel>
>>
>> Make sure to remove src/lxc/setns.h file which is automatically generated.
>>
>
>
------------------------------------------------------------------------------
Doing More with Less: The Next Generation Virtual Desktop
What are the key obstacles that have prevented many mid-market businesses
from deploying virtual desktops? How do next-generation virtual desktops
provide companies an easier-to-deploy, easier-to-manage and more affordable
virtual desktop model.http://www.accelacomm.com/jaw/sfnl/114/51426474/
_______________________________________________
Lxc-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/lxc-users