qemu-devel
[Top][All Lists]
Advanced

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

[Qemu-devel] qemu-img needs "-O host_device" describing


From: Adrian Bridgett
Subject: [Qemu-devel] qemu-img needs "-O host_device" describing
Date: Wed, 30 Sep 2009 22:27:36 +0100
User-agent: Mutt/1.5.20 (2009-06-14)

I've been trying to convert some personal KVM qemu (raw) file images
to raw LVs using kvm-img -O raw.  There's a short version and long
version of this tale.

The short version is "here is a patch to add '-O host_device' to the
manpage", perhaps we should also warn if "kvm-img convert -O raw" is
used on a block device (or even just automatically use host_device?)

The long version is that first of all I changed block/raw-posix.c so
that it didn't try and ftruncat() block devices and then eventually
tracked down why "kvm-img convert -O raw" fails to block devices (it
seeks past holes effectively which is good on files, but not block
devices).

Digging a bit deeper I found reference to "host_device" type and it
turns out that using that as an output format fixes both these issues
- with only one buglet - a hopefully irrelevant error:

  kvm-img convert -O host_device /var/lib/vm/bishop-disk 
/dev/rootvg/bishop-disk 
  Unknown option 'size'

This on qemu-kvm 0.11.

Thanks,

Adrian
-- 
bitcube.co.uk - Linux infrastructure consultancy
Puppet, Debian, Red Hat, Ubuntu, CentOS, ...

Attachment: qemu-truncate.diff
Description: Text Data

Attachment: qemu-host_device.diff
Description: Text Data


reply via email to

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