[systemd-devel] Issues with docker systemd cgroups integration

Daniel J Walsh dwalsh at redhat.com
Mon Mar 14 17:42:44 UTC 2016


Expanding this out to systemd-devel mailing list.

On 03/14/2016 01:04 PM, Mrunal Patel wrote:
> Hi, Lukas,
> We are using systemd cgroups support in docker for Fedora/RHEL and 
> seeing some issues.
>
> Here is the flow of the code in docker/runc/libcontainer:
> 1. We create a Transient Unit setting some properties based on what 
> the user passed or defaults.
> For e.g. /system.slice/docker-abcd.scope
> 2. We then manually join other cgroups subsystems such as devices by 
> creating the directory
> /sys/fs/cgroup/devices/system.slice/docker-abcd.scope. This is done so 
> we can support cgroups that aren't directly supported by systemd
>
> To see the code you can refer to 
> https://github.com/projectatomic/docker/pull/71/files (In this PR, I 
> made the change to always join all the subsystems after creating the 
> scope to help with first issue below).
>
>
> There are two classes of issues that are cropping up (especially under 
> load):
> 1. Sometimes a cgroup isn't joined even though it is passed as a 
> property while creating a Transient Unit. For e.g. CPUShares are 
> specified, however the transient unit doesn't seem to join
> the cpu,cpuacct subsystem.
>
> 2. cpu.proc file itself goes missing especitally with the devices 
> subsystemd even thought we mkdir the directory and write to the file. 
> It is as if the file gets deleted by some other process.
>
> What can we do to fix these issues?
>
> Thanks,
> Mrunal



More information about the systemd-devel mailing list