[pve-devel] applied: [PATCH ha-manager] fix #1842: do not pass forceStop to CT shutdown

Thomas Lamprecht t.lamprecht at proxmox.com
Wed Jan 23 10:01:24 CET 2019


The vm_shutdown parameter forceStop differs in behaviour between VMs
and CTs. While on VMs it ensures that a VM gets stoppped if it could
not shutdown gracefully only after the timeout passed, the container
stack always ignores any timeout if forceStop is set and hard stops
the CT immediately.
To achieve this behaviour for CTs too, the timeout is enough, as
lxc-stop then does the hard stop after timeout itself.

Signed-off-by: Thomas Lamprecht <t.lamprecht at proxmox.com>
---

trivial, and easy to reproduce => applied

 src/PVE/HA/Resources/PVECT.pm | 1 -
 1 file changed, 1 deletion(-)

diff --git a/src/PVE/HA/Resources/PVECT.pm b/src/PVE/HA/Resources/PVECT.pm
index 087df81..a0f05f4 100644
--- a/src/PVE/HA/Resources/PVECT.pm
+++ b/src/PVE/HA/Resources/PVECT.pm
@@ -83,7 +83,6 @@ sub shutdown {
 	node => $nodename,
 	vmid => $id,
 	timeout => $shutdown_timeout,
-	forceStop => 1,
     };
 
     my $upid = PVE::API2::LXC::Status->vm_shutdown($params);
-- 
2.20.1





More information about the pve-devel mailing list