From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Mdb2H-0002ld-0S for qemu-devel@nongnu.org; Tue, 18 Aug 2009 22:36:25 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Mdb2A-0002i9-RV for qemu-devel@nongnu.org; Tue, 18 Aug 2009 22:36:23 -0400 Received: from [199.232.76.173] (port=37501 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Mdb2A-0002i6-Md for qemu-devel@nongnu.org; Tue, 18 Aug 2009 22:36:18 -0400 Received: from [66.187.237.31] (port=53936 helo=mx2.redhat.com) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1Mdb2A-0004SU-5d for qemu-devel@nongnu.org; Tue, 18 Aug 2009 22:36:18 -0400 Received: from int-mx2.corp.redhat.com (int-mx2.corp.redhat.com [172.16.27.26]) by mx2.redhat.com (8.13.8/8.13.8) with ESMTP id n7J2A47G026666 for ; Tue, 18 Aug 2009 22:10:04 -0400 From: Juan Quintela Date: Wed, 19 Aug 2009 04:07:43 +0200 Message-Id: Subject: [Qemu-devel] [PATCH 0/6] Refactor autostart of machines List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Hi This series add several things: - delay sighandler_setup(). Current code hangs until you are using telnet:....,server for instance. With this change, ^C while waiting for telnet program to conect will kill the vm. - refactor autostart behaviour: * incoming migration: depend of -S parameter * loadvm from command line: depend of -S parameter * loadvm from monitor: same state that the vm it replaces * no loadvm no incoming: depend of -S parameter I tested, and all combinations works this way. - refactor do_loadvm(). do_loadvm() don't return errors, if there were any error while loading a vm, it would obey autostart value independently of the errors. Now it will never start a vm that had erros while loading. - if you type "cont" in the monitor of one machine just migrated, qemu will proceed with the start, with the consequent corruption. Last patch forbides to continue a vm that has just been migrated with an error message. If you load a new vm, flag is reset. This "bug/feature" was reported as a bug by users. One comment: - Is there really a good idea to allow loadvm in the monitor even if the current vm is running? I think that allowing loadvm command to only works when vm is stopped is a better idea. what does everybody else thinks? Comments? Later, Juan. Juan Quintela (6): Delay sighandler_setup() We want to autostart on incoming conections Once there, indent surrounded code in qemu style split do_loadvm() into do_loadvm() and load_vmstate() move do_loadvm() to monitor.c make load_vmstate() return errors Continue a migrated vm is a bad idea migration.c | 1 + monitor.c | 16 ++++++++++++++++ savevm.c | 19 +++++++------------ sysemu.h | 3 ++- vl.c | 24 +++++++++++++----------- 5 files changed, 39 insertions(+), 24 deletions(-)