vm-bhyve
vm-bhyve copied to clipboard
Double ACPI poweroff incompatible with illumos guests
Illumos ACPI driver in kernel interprets a second poweroff even within a timeout period as a "cancel" request.
Thus, vm stop <guestname>
won't shutdown an illumos guest:
Feb 1 13:37:34 omniosce power: [ID 199196 kern.notice] NOTICE: Power Button pressed 2 times, cancelling all requests
However, if we modify vm-core
to remove the second signal, it works fine:
root@freebsd:~ # diff vm-core.original /usr/local/lib/vm-bhyve/vm-core
656,657d655
< sleep 1
< kill "${_pid}" >/dev/null 2>&1
leads to proper shutdown.
If there is an important reason to keep the second SIGTERM, could we at least make it configurable?
Originally I was unable to get a Windows guest to shut down with a single call. I have no real idea why but Windows would just act like nothing happened. Two calls produced a fairly consistent poweroff. Could of just been something weird with my test machine of course.
I'll test again and see if I still have the same problem. Would be interesting if someone else running Windows tried to see if they get the same result.