libvirt's virSystemdCreateMachine (src/util/virsystemd.c) calls the systemd API `CreateMachineWithNetwork` via D-Bus to register machines. It works fine until systemd 225. However, with systemd 229, the `Before` property that is passed isn't accepted anymore and thus, makes the registration and creation of machines to fail.
Version-Release number of selected component (if applicable):
libvirtError: Cannot set property Before, or unknown property.
Expected results:
- The machine should be started properly:
a. `Before` shouldn't be passed,
b. `After` should probably not be passed either,
- A systemd registration failure should maybe not be critical.
Description of problem:
libvirt's virSystemdCreat eMachine (src/util/ virsystemd. c) calls the systemd API `CreateMachineW ithNetwork` via D-Bus to register machines. It works fine until systemd 225. However, with systemd 229, the `Before` property that is passed isn't accepted anymore and thus, makes the registration and creation of machines to fail.
Version-Release number of selected component (if applicable):
libvirt 1.2.17 (13.el7_2.5)
systemd 229 (+PAM +AUDIT +SELINUX +IMA -APPARMOR +SMACK -SYSVINIT +UTMP +LIBCRYPTSETUP +GCRYPT -GNUTLS -ACL +XZ -LZ4 +SECCOMP +BLKID -ELFUTILS +KMOD -IDN)
Steps to Reproduce:
0. Get an Ubuntu Xenial VM /wiki.ubuntu. com/SergeHallyn _libvirtnest , in particular: people. canonical. com/~serge/ cdboot. xml archive. ubuntu. com/ubuntu/ dists/precise/ main/installer- amd64/current/ images/ netboot/ mini.iso
1. apt-get install qemu-kvm libvirt-bin
2. Follow instructions at https:/
a. wget http://
b. wget -O mini.iso http://
c. qemu-img create cdboot.img 1G
d. virsh define cdboot.xml
e. virsh start cdboot
3. now apt-get install systemd-container
4. now virsh destroy cdboot; virsh start cdboot; it should fail
(https:/ /bugs.launchpad .net/ubuntu/ +source/ libvirt/ +bug/1529079/ comments/ 39)
Actual results:
libvirtError: Cannot set property Before, or unknown property.
Expected results:
- The machine should be started properly:
a. `Before` shouldn't be passed,
b. `After` should probably not be passed either,
- A systemd registration failure should maybe not be critical.
Additional info:
Issue reproduced on Ubuntu Xenial & CoreOS >1010.