From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:38855) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XGqTt-0002U2-Kz for qemu-devel@nongnu.org; Mon, 11 Aug 2014 10:21:58 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XGqTk-0006R7-J9 for qemu-devel@nongnu.org; Mon, 11 Aug 2014 10:21:49 -0400 Received: from mail-we0-x231.google.com ([2a00:1450:400c:c03::231]:62820) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XGqTk-0006R1-BZ for qemu-devel@nongnu.org; Mon, 11 Aug 2014 10:21:40 -0400 Received: by mail-we0-f177.google.com with SMTP id w62so8717882wes.36 for ; Mon, 11 Aug 2014 07:21:39 -0700 (PDT) Date: Mon, 11 Aug 2014 15:21:36 +0100 From: Stefan Hajnoczi Message-ID: <20140811142136.GA496@stefanha-thinkpad.redhat.com> References: <53E87FD1.3070600@huawei.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="pf9I7BMVVzbSWLtt" Content-Disposition: inline In-Reply-To: <53E87FD1.3070600@huawei.com> Subject: Re: [Qemu-devel] the whole virtual machine hangs when IO does not come back! List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Bin Wu Cc: qemu-devel@nongnu.org, peter.huangpeng@huawei.com --pf9I7BMVVzbSWLtt Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Aug 11, 2014 at 04:33:21PM +0800, Bin Wu wrote: > Hi, >=20 > I tested the reliability of qemu in the IPSAN environment as follows: > (1) create one VM on a X86 server which is connected to an IPSAN, and the= VM > has only one system volume which is on the IPSAN; > (2) disconnect the network between the server and the IPSAN. On the serve= r, > I have a "multipath" software which can hold the IO for a long time > (configurable) when the network is disconnected; > (3) about 30 seconds later, the whole VM hangs there, nothing can be done= to > the VM! >=20 > Then, I used "gstack" tool to collect the stacks of all qemu threads, it > looked like: >=20 > Thread 8 (Thread 0x7fd840bb5700 (LWP 6671)): > #0 0x00007fd84253a4f6 in poll () from /lib64/libc.so.6 > #1 0x00007fd84410ceff in aio_poll () > #2 0x00007fd84429bb05 in qemu_aio_wait () > #3 0x00007fd844120f51 in bdrv_drain_all () > #4 0x00007fd8441f1a4a in bmdma_cmd_writeb () > #5 0x00007fd8441f216e in bmdma_write () > #6 0x00007fd8443a93cf in memory_region_write_accessor () > #7 0x00007fd8443a94a6 in access_with_adjusted_size () > #8 0x00007fd8443a9901 in memory_region_iorange_write () > #9 0x00007fd8443a19bd in ioport_writeb_thunk () > #10 0x00007fd8443a13a8 in ioport_write () > #11 0x00007fd8443a1f55 in cpu_outb () > #12 0x00007fd8443a5b12 in kvm_handle_io () > #13 0x00007fd8443a64a9 in kvm_cpu_exec () > #14 0x00007fd844330962 in qemu_kvm_cpu_thread_fn () > #15 0x00007fd8427e77b6 in start_thread () from /lib64/libpthread.so.0 > #16 0x00007fd8425439cd in clone () from /lib64/libc.so.6 > #17 0x0000000000000000 in ?? () Use virtio-blk. Read, write, and flush are asynchronous in virtio-blk. Note that the QEMU monitor commands are typically synchronous so they will still block the VM. Stefan --pf9I7BMVVzbSWLtt Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQEcBAEBAgAGBQJT6NFwAAoJEJykq7OBq3PI6jIH/A6nCKOV4DL8I5HtfktELQ1G z918hZBG//+8dKnMpXzwphTecVLK8uositKEvDYXCEqXxBidL9Q3V6d66jEIDtyq aDWOvNhgOhXecR68ocuB+ZL5iGe2qBBqsF9zeyyrAve8eOXE1PoQnpuquXHuM1yn jaqcvVAxYVrlCPgobZvwtM7iiBpxIpbwsZc5n/lXSJ1Wrm4xJgLT5VXrilxb0r2z hSbf/8WTU+Q8wrAVA0cRWMcH86sPVZtsWqIDYSDKDIBHzG6cb1mAMvrY6XAwW/n1 sx47kCcWDgI/qJuNdgipU1nDHi/aqMqvxkLjHD0mdAjvZ5fDVlpQZyqZfhxs6YA= =y4aF -----END PGP SIGNATURE----- --pf9I7BMVVzbSWLtt--