]> git.ipfire.org Git - thirdparty/libvirt.git/commit
Fix launching of VMs on when only logind part of systemd is present
authorDaniel P. Berrange <berrange@redhat.com>
Wed, 11 Sep 2013 18:15:52 +0000 (19:15 +0100)
committerDaniel P. Berrange <berrange@redhat.com>
Thu, 12 Sep 2013 10:32:36 +0000 (11:32 +0100)
commita48838ad2e36c124229b6faaf6e24284810e3802
tree3f992c4e8c34c1b996ef9ff1ed6715be9347ff1c
parent621849383ad1aad61fe630184e689f5aca6ab7e0
Fix launching of VMs on when only logind part of systemd is present

Debian systems may run the 'systemd-logind' daemon, which causes the
/sys/fs/cgroup/systemd  mount to be setup, but no other cgroup
controllers are created. While the LXC driver considers cgroups to
be mandatory, the QEMU driver is supposed to accept them as optional.

We detect whether they are present by looking in /proc/mounts for
any mounts of type 'cgroups', but this is not sufficient. We need to
skip any named mounts (as seen by a name=XXX string in the mount
options), so that we only detect actual resource controllers.

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=721979

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
src/util/vircgroup.c
tests/vircgroupmock.c
tests/vircgrouptest.c