qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Stefan Hajnoczi <stefanha@redhat.com>
To: qemu-devel@nongnu.org
Cc: Kevin Wolf <kwolf@redhat.com>,
	Paolo Bonzini <pbonzini@redhat.com>,
	bluewindow@h3c.com, nick@bytemark.co.uk
Subject: [Qemu-devel] [PATCH v2 0/3] nbd: fix issues when connection breaks
Date: Wed, 26 Feb 2014 15:30:17 +0100	[thread overview]
Message-ID: <1393425020-24829-1-git-send-email-stefanha@redhat.com> (raw)

v2:
 * Use qemu-iotests 083 test number to avoid conflicts [kwolf]
 * Test class negotiation without export name [lupine]
 * Test short replies from the server [lupine]

The first patch ensures the nbd_receive_reply() fd handler is unregistered when
the connection to the server breaks.  This avoids high CPU consumption and
flooding error messages.

The second patch introduces an NBD server fault injection script.  Using this
fake NBD server it is possible to exercise error handling code paths in the NBD
client.

The third patch adds qemu-iotests test case 083 to verify qemu-io exits with an
error at each point where the connection can break.

Stefan Hajnoczi (3):
  nbd: close socket if connection breaks
  tests: add nbd-fault-injector.py utility
  qemu-iotests: add 083 NBD client disconnect tests

 block/nbd-client.c                       |  33 ++--
 tests/qemu-iotests/083                   | 129 +++++++++++++++
 tests/qemu-iotests/083.out               | 163 +++++++++++++++++++
 tests/qemu-iotests/group                 |   1 +
 tests/qemu-iotests/nbd-fault-injector.py | 264 +++++++++++++++++++++++++++++++
 5 files changed, 575 insertions(+), 15 deletions(-)
 create mode 100755 tests/qemu-iotests/083
 create mode 100644 tests/qemu-iotests/083.out
 create mode 100755 tests/qemu-iotests/nbd-fault-injector.py

-- 
1.8.5.3

             reply	other threads:[~2014-02-26 14:31 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-26 14:30 Stefan Hajnoczi [this message]
2014-02-26 14:30 ` [Qemu-devel] [PATCH v2 1/3] nbd: close socket if connection breaks Stefan Hajnoczi
2014-02-26 14:30 ` [Qemu-devel] [PATCH v2 2/3] tests: add nbd-fault-injector.py utility Stefan Hajnoczi
2014-02-26 14:30 ` [Qemu-devel] [PATCH v2 3/3] qemu-iotests: add 083 NBD client disconnect tests Stefan Hajnoczi
2014-03-12  9:17 ` [Qemu-devel] [PATCH v2 0/3] nbd: fix issues when connection breaks Stefan Hajnoczi
2014-03-12 18:01   ` Paolo Bonzini
2014-03-13 12:31     ` Stefan Hajnoczi
2014-03-14 15:30 ` Stefan Hajnoczi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1393425020-24829-1-git-send-email-stefanha@redhat.com \
    --to=stefanha@redhat.com \
    --cc=bluewindow@h3c.com \
    --cc=kwolf@redhat.com \
    --cc=nick@bytemark.co.uk \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).