]> git.proxmox.com Git - qemu-server.git/commitdiff
change shutdown behaviour on suspended vm
authorDominik Csapak <d.csapak@proxmox.com>
Tue, 12 Apr 2016 08:54:21 +0000 (10:54 +0200)
committerDietmar Maurer <dietmar@proxmox.com>
Tue, 12 Apr 2016 15:18:55 +0000 (17:18 +0200)
previously, when shutting down a suspended vm,
we successfully send the shutdown command to it,
but it will not shutdown (because it is suspended)

there we will run into the timeout and either
bail out with an error, or kill the process

when we not kill the process and resume the vm,
it will instantly shutdown, because of the previous
command

this patch checks the status of the vm beforehand,
and either bails out with an error that you cannot
shutdown a suspended vm, or stops the vm with the
correct qmp command (depending of forceStop)

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>

No differences found