qemu: virtiofs: kill the whole process group

Send TERM/KILL to virtiofsd and its child processes too
and do not exit until they are all dead.

https://bugzilla.redhat.com/show_bug.cgi?id=1940276

Signed-off-by: Ján Tomko <jtomko@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
Tested-by: Masayoshi Mizuma <m.mizuma@jp.fujitsu.com>
This commit is contained in:
Ján Tomko 2021-08-03 16:56:41 +02:00
parent ff7b8043b6
commit ca43a5198a

View File

@ -281,7 +281,7 @@ qemuVirtioFSStop(virQEMUDriver *driver G_GNUC_UNUSED,
if (!(pidfile = qemuVirtioFSCreatePidFilename(vm, fs->info.alias)))
goto cleanup;
if (virPidFileForceCleanupPath(pidfile) < 0) {
if (virPidFileForceCleanupPathFull(pidfile, true) < 0) {
VIR_WARN("Unable to kill virtiofsd process");
} else {
if (QEMU_DOMAIN_FS_PRIVATE(fs)->vhostuser_fs_sock)