From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:48114) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QoC7F-0003qo-Iw for qemu-devel@nongnu.org; Tue, 02 Aug 2011 06:22:26 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QoC7E-0002ut-Bo for qemu-devel@nongnu.org; Tue, 02 Aug 2011 06:22:25 -0400 Received: from mx1.redhat.com ([209.132.183.28]:40060) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QoC7E-0002ue-4x for qemu-devel@nongnu.org; Tue, 02 Aug 2011 06:22:24 -0400 Date: Tue, 2 Aug 2011 11:22:15 +0100 From: "Daniel P. Berrange" Message-ID: <20110802102215.GA2534@redhat.com> References: <20110727154229.656532d4@doriath> <4E310E6A.6000004@redhat.com> <20110728103143.548d7bb1@doriath> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20110728103143.548d7bb1@doriath> Subject: Re: [Qemu-devel] [RFC] Introduce vm_stop_permanent() Reply-To: "Daniel P. Berrange" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Luiz Capitulino Cc: Blue Swirl , Jan Kiszka , Avi Kivity , qemu-devel On Thu, Jul 28, 2011 at 10:31:43AM -0300, Luiz Capitulino wrote: > On Thu, 28 Jul 2011 10:23:22 +0300 > Avi Kivity wrote: > > > On 07/28/2011 12:44 AM, Blue Swirl wrote: > > > On Wed, Jul 27, 2011 at 9:42 PM, Luiz Capitulino wrote: > > > > This function should be used when the VM is not supposed to resume > > > > execution (eg. by issuing 'cont' monitor command). > > > > > > > > Today, we allow the user to resume execution even when: > > > > > > > > o the guest shuts down and -no-shutdown is used > > > > o there's a kvm internal error > > > > o loading the VM state with -loadvm or "loadvm" in the monitor fails > > > > > > > > I think only badness can happen from the cases above. > > > > > > I'd suppose a system_reset should bring the system back to sanity and > > > then clear vm_permanent_stopped (where's -ly?) > > What's -ly? > > > > except maybe for KVM > > > internal error if that can't be recovered. Then it would not very > > > permanent anymore, so the name would need adjusting. > > > > Currently, all kvm internal errors are recoverable by reset (and > > possibly by fiddling with memory/registers). > > Ok, but a poweroff in the guest isn't recoverable with system_reset > right? Or does it depend on the guest? > > I get funny results if qemu is started with -no-shutdown and I run cont after > a poweroff in a F15 guest. Sometimes qemu will exit after a few seconds, > sometimes 'info status' will say 'running'. libvirt uses this approach to fake a controlled soft reboot of guests. eg $ qemu .... -no-shutdown ...some time later... system_shutdown ...wait for SHUTDOWN event... system_reset cont Previous releases of QEMU had a bug in some device backends which would cause a crash sometimes, but in general it ought to work IMHO. Daniel -- |: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :| |: http://libvirt.org -o- http://virt-manager.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|