From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:51845) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TbR6R-00047F-W9 for qemu-devel@nongnu.org; Thu, 22 Nov 2012 02:21:41 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TbR6Q-0004Dz-0L for qemu-devel@nongnu.org; Thu, 22 Nov 2012 02:21:39 -0500 Received: from [222.73.24.84] (port=59551 helo=song.cn.fujitsu.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TbR6P-0004DA-IJ for qemu-devel@nongnu.org; Thu, 22 Nov 2012 02:21:37 -0500 Date: Thu, 22 Nov 2012 15:21:28 +0800 From: Hu Tao Message-ID: <20121122072128.GH17217@localhost.localdomain> References: <0a2274eccf1b1dd420f16359f7e1de74fa2f9fbe.1351131144.git.hutao@cn.fujitsu.com> <20121031011256.GC12325@amt.cnet> <50908354.5070608@cn.fujitsu.com> <20121106015835.GA11971@localhost.localdomain> <20121113021908.GA8176@amt.cnet> <20121120100948.GB17311@localhost.localdomain> <20121120213349.GA31355@amt.cnet> <20121121093928.GN21208@redhat.com> MIME-Version: 1.0 In-Reply-To: <20121121093928.GN21208@redhat.com> Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Subject: Re: [Qemu-devel] [PATCH v11] kvm: notify host when the guest is panicked List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Marcelo Tosatti Cc: Andrew Jones , Gleb Natapov , Jan Kiszka , qemu-devel , "linux-kernel@vger.kernel.org" , Blue Swirl , Sasha Levin , kvm list , Luiz Capitulino , KAMEZAWA Hiroyuki , Avi Kivity On Wed, Nov 21, 2012 at 11:39:28AM +0200, Gleb Natapov wrote: > On Tue, Nov 20, 2012 at 07:33:49PM -0200, Marcelo Tosatti wrote: > > On Tue, Nov 20, 2012 at 06:09:48PM +0800, Hu Tao wrote: > > > Hi Marcelo, > > > > > > On Tue, Nov 13, 2012 at 12:19:08AM -0200, Marcelo Tosatti wrote: > > > > On Fri, Nov 09, 2012 at 03:17:39PM -0500, Sasha Levin wrote: > > > > > On Mon, Nov 5, 2012 at 8:58 PM, Hu Tao wrote: > > > > > > But in the case of panic notification, more dependency means more > > > > > > chances of failure of panic notification. Say, if we use a virtio device > > > > > > to do panic notification, then we will fail if: virtio itself has > > > > > > problems, virtio for some reason can't be deployed(neither built-in or > > > > > > as a module), or guest doesn't support virtio, etc. > > > > > > > > > > Add polling to your virtio device. If it didn't notify of a panic but > > > > > taking more than 20 sec to answer your poll request you can assume > > > > > it's dead. > > > > > > > > > > Actually, just use virtio-serial and something in userspace on the guest. > > > > > > > > They want the guest to stop, so a memory dump can be taken by management > > > > interface. > > > > > > > > Hu Tao, lets assume port I/O is the preferred method for communication. > > > > > > Okey. > > > > > > > Now, the following comments have still not been addressed: > > > > > > > > 1) Lifecycle of the stopped guest and interaction with other stopped > > > > states in QEMU. > > > > > > Patch 3 already deals with run state transitions. But in case I'm > > > missing something, could you be more specific? > > > > - What are the possibilities during migration? Say: > > - migration starts. > > - guest panics. > > - migration starts vm on other side? > > - Guest stopped due to EIO. > > - guest vcpuN panics, VMEXIT but still outside QEMU. > > - QEMU EIO error, stop vm. > > - guest vcpuN completes, processes IO exit. > > - system_reset due to panic. > > - Add all possibilities that should be verified (that is, interaction > > of this feature with other stopped states in QEMU). Thank you for your explanation! > > > BTW I do remember getting asserts while using breakpoints via gdbstub > and stop/cont from the monitor. Thanks, I'll consider this too. > > > --- > > > > - What happens if the guest has reboot-on-panic configured? Does it take > > precedence over hypervisor notification? Yes. But I don't think this is what we want if pv-event is on. Users may want to do whatever they want when the guest is panicked, but not an automatic reboot-on-panic. What's your opinion? > > > > > > > > Out of curiosity, does kexec support memory dumping? Yes. do we have to disable kexec if pv-event is on, too? > > > > > > 2) Format of the interface for other architectures (you can choose > > > > a different KVM supported architecture and write an example). > > > > > > > > 3) Clear/documented management interface for the feature. > > > > > > It is documented in patch 0: Documentation/virtual/kvm/pv_event.txt. > > > Does it need to be improved? > > > > This is documentation for the host<->guest interface. There is no > > documentation on the interface for management. Oh yes, I'll add this. -- Thanks, Hu Tao