[Libguestfs] [PATCH v8 2/4] v2v: add function qemu_img_version to utils

Richard W.M. Jones rjones at redhat.com
Mon Feb 6 20:04:41 UTC 2017


On Mon, Feb 06, 2017 at 07:25:23PM +0100, Tomáš Golembiovský wrote:
> No we don't. Something like this also works:
> 
>     qemu-img info 'json:{ "offset": 0, "file": { "filename": "/dev/null" } }'

/dev/null has a long history of breaking qemu (although it does work
at the moment), eg:

  https://bugzilla.redhat.com/show_bug.cgi?id=847549

Libguestfs has a workaround for this in fact:

  https://github.com/libguestfs/libguestfs/blob/master/lib/drives.c#L395

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming and virtualization blog: http://rwmj.wordpress.com
virt-df lists disk usage of guests without needing to install any
software inside the virtual machine.  Supports Linux and Windows.
http://people.redhat.com/~rjones/virt-df/




More information about the Libguestfs mailing list