[Libguestfs] Comment on libguestfs code in https://bitbucket.org/swamiyeswanth/pyti

Richard W.M. Jones rjones at redhat.com
Thu Jun 16 16:02:24 UTC 2011


On Thu, Jun 16, 2011 at 09:14:14PM +0530, (   [YeSwAnTh]   )- wrote:
> 1)How do i handle .vdi images in guestfs.

We support whatever qemu supports.  It turns out that usually *.vdi
files "just work":

https://rwmj.wordpress.com/2010/10/04/tip-open-virtualbox-vdi-file-using-libguestfs/

If it doesn't work, then it's a qemu problem, so best to contact them.
(Or you could use another format like raw instead).

> the guestfs_add_drive_opts mentions only qcow2 and raw image
> formats.

You don't have to set the format parameter - it's optional.  If it's
not set, then qemu will autodetect it (as happens with 'add_drive').
Autodetection is unsafe if you don't trust your guests.

[test plan]
> What do you think of this?

Sounds perfectly reasonable.

Rich.

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




More information about the Libguestfs mailing list