]> git.ipfire.org Git - thirdparty/libvirt.git/commit
vircgroup: use DBus call to systemd for some APIs
authorPavel Hrdina <phrdina@redhat.com>
Fri, 5 Feb 2021 15:17:35 +0000 (16:17 +0100)
committerPavel Hrdina <phrdina@redhat.com>
Wed, 10 Feb 2021 12:37:12 +0000 (13:37 +0100)
commit9c1693eff427661616ce1bd2795688f87288a412
treead511f508aa0acc9d49d50c2a226a8394217d0fa
parentd3fb774b1ed548c0338b3338a87094dafea32aa2
vircgroup: use DBus call to systemd for some APIs

When running on host with systemd we register VMs with machined.
In this case systemd creates the root VM cgroup for us. This has some
implications where one of them is that systemd owns all files inside
the root VM cgroup and we should not touch them.

If we change any value in file that systemd knows about it will be
changed to what systemd thinks it should be when executing
`systemctl daemon-reload`.

These are the APIs that we need to call using systemd because they set
limits that are proportional to sibling cgroups.

Signed-off-by: Pavel Hrdina <phrdina@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
src/util/vircgroup.c
src/util/vircgrouppriv.h
src/util/vircgroupv1.c
src/util/vircgroupv2.c