Re: [Qemu-devel] [PATCH 2/3] tests: add nbd-fault-injector.py utility

2014-02-25 Thread Stefan Hajnoczi
On Tue, Feb 25, 2014 at 11:45:11AM +, Nick Thomas wrote: > On 25/02/14 10:09, Stefan Hajnoczi wrote: > > +def send(self, buf, event): > > +self.check(event, 'write', 'before') > > +self.sock.sendall(buf) > > +self.check(event, 'write', 'after') > > + > > +def rec

Re: [Qemu-devel] [PATCH 2/3] tests: add nbd-fault-injector.py utility

2014-02-25 Thread Nick Thomas
Hi, On 25/02/14 10:09, Stefan Hajnoczi wrote: > The nbd-fault-injector.py script is a special kind of NBD server. It > throws away all writes and produces zeroes for reads. Given a list of > fault injection rules, it can simulate NBD protocol errors and is useful > for testing NBD client error h

[Qemu-devel] [PATCH 2/3] tests: add nbd-fault-injector.py utility

2014-02-25 Thread Stefan Hajnoczi
The nbd-fault-injector.py script is a special kind of NBD server. It throws away all writes and produces zeroes for reads. Given a list of fault injection rules, it can simulate NBD protocol errors and is useful for testing NBD client error handling code paths. See the patch for documentation.