[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [Bug 1217339] [NEW] SIGQUIT to send ACPI-shutdown to Gu
From: |
Laszlo Ersek |
Subject: |
Re: [Qemu-devel] [Bug 1217339] [NEW] SIGQUIT to send ACPI-shutdown to Guest |
Date: |
Tue, 27 Aug 2013 16:38:37 +0200 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130806 Thunderbird/17.0.8 |
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
qemu_system_shutdown_request() on POSIX:
termsig_handler() [os-posix.c]
qemu_system_killed() [vl.c]
qemu_system_shutdown_request()
Laszlo
[Prev in Thread] |
Current Thread |
[Next in Thread] |