Weird new structure in my cgroups

Ovidiu

Renowned Member
Apr 27, 2014
326
14
83
I recently noticed these "ns" folders, any idea what that is about?

Code:
/sys/fs/cgroup/memory
/sys/fs/cgroup/memory/lxc
/sys/fs/cgroup/memory/lxc/100
/sys/fs/cgroup/memory/lxc/100/ns
/sys/fs/cgroup/memory/lxc/102
/sys/fs/cgroup/memory/lxc/102/ns
/sys/fs/cgroup/memory/lxc/104
/sys/fs/cgroup/memory/lxc/104/ns
/sys/fs/cgroup/memory/lxc/105
/sys/fs/cgroup/memory/lxc/105/ns
/sys/fs/cgroup/memory/lxc/108
/sys/fs/cgroup/memory/lxc/108/ns
 
see https://git.proxmox.com/?p=lxc.git;a=commitdiff;h=308c8a3ef9e7cb2becde9743c62c2252bd9474f2 , the commit message for the first patch gives a good summary:

When cgroup namespaces are enabled a privileged container with mixed cgroups has full write access to its own root cgroup effectively allowing it to overwrite values written from the outside or configured via lxc.cgroup.*.

This patch causes an additional 'ns/' directory to be created in all cgroups if cgroup namespaces and cgfsng are being used in order to combat this.
 
  • Like
Reactions: Ovidiu
I configured "lxc.cgroup.blkio.throttle.write_bps_device" value
in "/sys/fs/cgroup/blkio/lxc/115/blkio.throttle.write_bps_device" OK
but in "/sys/fs/cgroup/blkio/lxc/115/ns/blkio.throttle.write_bps_device" is empty
so throttling not working until I write directly to "/sys/fs/cgroup/blkio/lxc/115/ns/blkio.throttle.write_bps_device"
why?
 
see my previous reply ;)