Systemd 205 starts conversion process to cgroups usage
Lennart Poettering has announced the release of systemd 205, the latest version of the system management tool. This release takes the first steps towards, in the medium term, taking control of interactions with the kernel's cgroups. In recent kernel versions, cgroups can be used to govern the allocation of system resources like CPU time, memory usage or storage quotas.
The systemd changes are happening in concert with the maintainer of the cgroup code in the kernel. This code has undergone significant changes in the last few months to alleviate design flaws in the subsystem, which has been much maligned. The current plans call for systemd to become the central controlling mechanism for interactions between userland code and the cgroup configuration of the kernel. Under the new architecture, applications will not manipulate the cgroup configuration themselves, but will send requests to do so over an API to systemd. Details of how the new model will work were recently publicised by the developers of systemd and the cgroup maintainer.
As part of this roadmap, systemd now loses a number of configuration parameters that directly manipulate cgroups. These will be migrated to new functions that are being implemented under the new model. These functions include the new scope and slice unit types. Scope units are similar to the service units that are used when starting processes, but, unlike them, they are not generated by the init process itself, but rather by already running processes; daemons and applications can therefore use them to group processes they spawned. Slice units, on the other hand, are used when partitioning a system. Out of the box, three slices are provided: one for system processes, one for user sessions and one for virtual machines and containers.
Additionally, the new systemd version also introduces the "mini-daemon"
systemd-machined, which manages virtual machines and containers. The new tool also collects metadata on its charges that can be queried with the
Systemd can be downloaded from the Freedesktop.org servers. Its source code is licensed under the LGPLv2.1 or later.