[lxc-users] Naming under /sys/fs/cgroup in LXC container

John Marshall John.Marshall at ssc-spc.gc.ca
Fri Jul 24 15:15:22 UTC 2015


Hi,

I have all my controllers under a common directory /sys/fs/cgroup/unified:

    cgroup on /sys/fs/cgroup/unified type cgroup (rw,relatime,hugetlb,perf_event,blkio,freezer,devices,memory,cpuacct,cpu,cpuset)

under which is a "jobs" cgroup running jobs in jobs/<jobid>. When I start an LXC container,
e.g., under /jobs/123, and have this in my lxc config file:

    lxc.mount.auto = cgroup
    lxc.aa_profile = unconfined

I get the following under /sys/fs/cgroup (in the container):

    lrwxrwxrwx 1 root root 66 Jul 24 14:47 blkio -> hugetlb,perf_event,blkio,freezer,devices,memory,cpuacct,cpu,cpuset
    lrwxrwxrwx 1 root root 66 Jul 24 14:47 cpu -> hugetlb,perf_event,blkio,freezer,devices,memory,cpuacct,cpu,cpuset
    lrwxrwxrwx 1 root root 66 Jul 24 14:47 cpuacct -> hugetlb,perf_event,blkio,freezer,devices,memory,cpuacct,cpu,cpuset
    lrwxrwxrwx 1 root root 66 Jul 24 14:47 cpuset -> hugetlb,perf_event,blkio,freezer,devices,memory,cpuacct,cpu,cpuset
    lrwxrwxrwx 1 root root 66 Jul 24 14:47 devices -> hugetlb,perf_event,blkio,freezer,devices,memory,cpuacct,cpu,cpuset
    lrwxrwxrwx 1 root root 66 Jul 24 14:47 freezer -> hugetlb,perf_event,blkio,freezer,devices,memory,cpuacct,cpu,cpuset
    lrwxrwxrwx 1 root root 66 Jul 24 14:47 hugetlb -> hugetlb,perf_event,blkio,freezer,devices,memory,cpuacct,cpu,cpuset
    drwxr-xr-x 3 root root 60 Jul 24 14:47 hugetlb,perf_event,blkio,freezer,devices,memory,cpuacct,cpu,cpuset
    lrwxrwxrwx 1 root root 66 Jul 24 14:47 memory -> hugetlb,perf_event,blkio,freezer,devices,memory,cpuacct,cpu,cpuset
    lrwxrwxrwx 1 root root 66 Jul 24 14:47 perf_event -> hugetlb,perf_event,blkio,freezer,devices,memory,cpuacct,cpu,cpuset

Is there some way to get this exposed under a single directory (e.g., /sys/fs/cgroup/unified)
as I do on the host system rather than entries for all the controllers? In effect could the
directory "hugetlb,perf_event,blkio,freezer,devices,memory,cpuacct,cpu,cpuset" be given
a name "unified" instead?

Thanks,
John

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20150724/74cb6038/attachment.html>


More information about the lxc-users mailing list