qemu/kvm are instantly SIGKILLed by systemd on shutdown, without wait. Description of problem: systemd assumes it cannot terminate qemu, and SIGKILLs it. Instantly. Steps to reproduce: 1. Start qemu on a systemd managed host 2. Shutdown/Reboot Additional information: Nothing on qemu's own log, besides that it is starting a vnc server. ```plaintext # journalctl -b -1 ... Sep 22 18:38:04 local kernel: kvm_amd: TSC scaling supported Sep 22 18:38:04 local kernel: kvm_amd: Nested Virtualization enabled Sep 22 18:38:04 local kernel: kvm_amd: Nested Paging enabled Sep 22 18:38:04 local kernel: kvm_amd: Virtual VMLOAD VMSAVE supported Sep 22 18:38:04 local kernel: kvm_amd: Virtual GIF supported Sep 22 18:38:04 local kernel: kvm_amd: LBR virtualization supported ... Sep 22 18:38:50 local systemd-logind[721]: The system will reboot now! Sep 22 18:38:50 local systemd-logind[721]: System is rebooting. Sep 22 18:38:50 local sddm-helper[850]: Signal received: SIGTERM ... Sep 22 18:38:50 local systemd[1]: Stopping User Manager for UID 1000... Sep 22 18:38:50 local systemd-logind[721]: Removed session 1. Sep 22 18:38:50 local systemd[854]: Activating special unit Exit the Session... Sep 22 18:38:50 local systemd[854]: app-org.kde.konsole-1ab3dac6a1db4b29b55899b477b32975.scope: Failed to kill control group /user.slice/user-1000.slice/user@1000.service/app.slice/> Sep 22 18:38:50 local systemd[854]: app-org.kde.konsole-1ab3dac6a1db4b29b55899b477b32975.scope: Killing process 1708 (qemu-system-x86) with signal SIGKILL. Sep 22 18:38:50 local systemd[854]: app-org.kde.konsole-1ab3dac6a1db4b29b55899b477b32975.scope: Killing process 1712 (kvm-nx-lpage-recovery-1708) with signal SIGKILL. Sep 22 18:38:50 local systemd[854]: app-org.kde.konsole-1ab3dac6a1db4b29b55899b477b32975.scope: Failed to kill control group /user.slice/user-1000.slice/user@1000.service/app.slice/> Sep 22 18:38:50 local systemd[854]: Stopped Konsole - Terminal. ... (some other applications terminanting normally ) Sep 22 18:38:50 local systemd[854]: app-org.kde.konsole-1ab3dac6a1db4b29b55899b477b32975.scope: Consumed 10.068s CPU time. Sep 22 18:38:50 local systemd[854]: Removed slice User Background Tasks Slice. Sep 22 18:38:50 local systemd[854]: background.slice: Consumed 2.960s CPU time. ... ``` I cannot explain why it sends SIGKILL to qemu/kvm... it is the same second as the shutdown started, their docs says there's a delay for that. Also, other processes owned by the user received a single SIGTERM after qemu was SIGKILLed. Some even take a couple seconds to exit and are not SIGKILLed.