qemu-block
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-block] Disconecting /dev/nbdX leaves stale partitions and devi


From: Richard W.M. Jones
Subject: Re: [Qemu-block] Disconecting /dev/nbdX leaves stale partitions and device
Date: Fri, 27 Jul 2018 15:06:54 +0100
User-agent: Mutt/1.5.21 (2010-09-15)

On Fri, Jul 27, 2018 at 02:20:29PM +0100, Stefan Hajnoczi wrote:
> On Thu, Jul 19, 2018 at 01:56:34PM +0300, Nir Soffer wrote:
> > Having HTTP API makes it easy to integrate with. This is also the protocol
> > Kubrvirt CDI[1] is using for importing images:
> > https://github.com/kubevirt/containerized-data-importer
> 
> 2 options:
> 
> 1. Write a server that does HTTP<->NBD.  Less efficient but fairly easy
>    to do in Go, Python, etc.

We did this one in reverse already:
https://github.com/libguestfs/libguestfs/blob/master/v2v/rhv-upload-plugin.py

The problem is that HTTP sucks as a block device transport protocol.

We have over time ended up adding an ad-hoc, informally-specified
etc.. implementation of the NBD protocol, except over HTTPS.  For
example we've reimplemented zeroing and trimming as special
non-standard HTTP methods.  Then we discovered that performance still
sucked so we implemented a (non-standard) HTTP-over-Unix-domain-socket
transport, which of course nothing is able to connect to so we had to
modify the Python HTTP client to use it.  Performance still isn't
great so the next step is to enable pipelining.  NBD solves all of
this already so we should just be using NBD, and we can use qemu-nbd
as the server.

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming and virtualization blog: http://rwmj.wordpress.com
virt-top is 'top' for virtual machines.  Tiny program with many
powerful monitoring features, net stats, disk stats, logging, etc.
http://people.redhat.com/~rjones/virt-top



reply via email to

[Prev in Thread] Current Thread [Next in Thread]