From: Daniel P. Berrange Date: Fri, 13 Jul 2012 11:49:55 +0000 (+0100) Subject: Don't autostart domains when reloading config X-Git-Tag: v0.9.11.5~28 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=f81800cf231200766d99e5e457e788dff3ea29dc;p=thirdparty%2Flibvirt.git Don't autostart domains when reloading config When sending SIGHUP to libvirtd, it will trigger the virStateDriver reload operation. This is intended to reload the configuration files for guests. For unknown historical reasons this is also triggering autostart of all guests. Autostart is generally expected to be something that happens on OS startup. Starting VMs on SIGHUP will violate that expectation and potentially cause dangerous scenarios if the admin has explicitly shutdown a misbehaving VM that has been marked as autostart Signed-off-by: Daniel P. Berrange (cherry picked from commit 95c2c19f06298a6e93849d9a5da8161460c33f43) --- diff --git a/src/lxc/lxc_driver.c b/src/lxc/lxc_driver.c index 36dd1c5126..fcdf6eb625 100644 --- a/src/lxc/lxc_driver.c +++ b/src/lxc/lxc_driver.c @@ -2687,8 +2687,6 @@ lxcReload(void) { lxcNotifyLoadDomain, lxc_driver); lxcDriverUnlock(lxc_driver); - lxcAutostartConfigs(lxc_driver); - return 0; } diff --git a/src/qemu/qemu_driver.c b/src/qemu/qemu_driver.c index 0286e16562..26515d74b7 100644 --- a/src/qemu/qemu_driver.c +++ b/src/qemu/qemu_driver.c @@ -783,8 +783,6 @@ qemudReload(void) { qemudNotifyLoadDomain, qemu_driver); qemuDriverUnlock(qemu_driver); - qemuAutostartDomains(qemu_driver); - return 0; } diff --git a/src/uml/uml_driver.c b/src/uml/uml_driver.c index 26fc13b3d7..8f300f01da 100644 --- a/src/uml/uml_driver.c +++ b/src/uml/uml_driver.c @@ -553,8 +553,6 @@ umlReload(void) { umlNotifyLoadDomain, uml_driver); umlDriverUnlock(uml_driver); - umlAutostartConfigs(uml_driver); - return 0; }