[libvirt] libvirt-guests.sh stop

Henning Schild henning.schild at siemens.com
Mon Dec 9 21:52:38 UTC 2019


Hi all,

the shellscript causing VMs to eventually stop when the host shuts
down/reboots has a window where it can loose ACPI shutdown events.

I have seen VMs not shutting down before they become ACPI aware,
causing the systemd magic to time out for a couple of minutes and
eventually killing the VM.

Steps to reproduce:
 - start a new VM
 - reboot the host while the VM is still booting up

What happens:
 - the ACPI power-button event will get lost
 - the systemd loop on the host will go and wait
 - the VM will get killed hard eventually

What should happen (probably):
 - the retry loop should inject an ACPI power-button-event with every
   retry (5s?)
 - the VM will eventually have ACPI support and pick up any of the
   many button-events
 - the VM will shut down on any of the many power-button events, if
   there was enough time

I could try to come up with a patch, but i hope the description of the
problem is clear enough so someone else will try.

regards,
Henning





More information about the libvir-list mailing list