SIGQUIT to send ACPI-shutdown to Guest
Bug #1217339 reported by
Lasse
This bug affects 2 people
| Affects | Status | Importance | Assigned to | Milestone | |
|---|---|---|---|---|---|
| QEMU |
Invalid
|
Wishlist
|
Unassigned | ||
Bug Description
When qemu receives SIGQUIT, it should first try to run system_powerdown (giving the guest an ACPI signal to begin the shutdown process), before ending the whole qemu process.
At this point there is no way to do a graceful shutdown if you do not have access to the monitor and you do not use any wrapper like libvirt.
If, for some reason SIGQUIT would not be accepted as the signal, take any free to use signal, like SIGUSR1. There should be a way to get ACPI shutdown sent to the guest.
| Changed in qemu: | |
| importance: | Undecided → Wishlist |
To post a comment you must log in.

On 08/27/13 14:29, Lasse wrote:
> Public bug reported:
>
> When qemu receives SIGQUIT, it should first try to run system_powerdown
> (giving the guest an ACPI signal to begin the shutdown process), before
> ending the whole qemu process.
I strongly disagree. SIGQUIT is an interactive debugging signal. It is
there so that the user running qemu can trigger a core dump from the
terminal, when he/she notices a problem.
http:// www.gnu. org/software/ libc/manual/ html_node/ Termination- Signals. html#index- SIGQUIT- 2854
> At this point there is no way to do a graceful shutdown if you do not
> have access to the monitor and you do not use any wrapper like libvirt.
>
> If, for some reason SIGQUIT would not be accepted as the signal, take
> any free to use signal, like SIGUSR1. There should be a way to get ACPI
> shutdown sent to the guest.
What's wrong with SIGINT / SIGTERM? Those signals are there to request a
clean shutdown (from the terminal and from an unrelated process,
respectively).
As far as I can see, both SIGINT and SIGTERM end up in shutdown_ request( ) on POSIX:
qemu_system_
termsig_handler() [os-posix.c] system_ killed( ) [vl.c] system_ shutdown_ request( )
qemu_
qemu_
Laszlo