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