[et-mgmt-tools] [PATCH] can not specify the type of driver device
fukuta.saori at jp.fujitsu.com
Wed Jul 11 06:01:10 UTC 2007
On Tue, 10 Jul 2007 01:26:24 +0100 "Daniel P. Berrange" wrote:
> On Mon, Jul 02, 2007 at 06:29:03PM +0900, Saori Fukuta wrote:
> > Hi,
> > I opened the new bugzilla:
> > Bugzilla Bug 246441: can not specify the type of driver device
> > URL: https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=246441
> > And I attached the patch to fix this problem.
> There seems to be two different use cases for the driver type, and I'm
> not sure which one you are trying to address. The patch seems to be just
> giving the user the ability to specify a sub-type for blktap based files.
I found out my mistake by your comment. Thank you.
There are two kinds of the meaning for the "driver type" now. The one
of the kind is using for operating the disk, and another is using for
creating the disk. Is that right?
So do we need following two options ?
1) --sub-type = SUBTYPE
2) --disk-format = DISKFMT
And I am trying to address the former (--sub-type).
The "--sub-type" option that actually I wanted to add is choosing the
mode for operating the disk. As you said, this is just giving the user
the ability to specify a sub-type for blktap based files.
For example, I meant that was "driver type" of XML configuration:
<disk type='file' device='disk'>
<driver name='tap' type='sync'/> <---"driver type"
So we have to prepare the name of sub type:
SUB_TYPE_AIO = "aio"
SUB_TYPE_SYNC = "sync"
and add "--sub-type" option.
The "--disk-format" option that you offered is choosing the format type
for creating disk. If we want to choose the format type, we have to
prepare following name of format type:
DRIVER_TAP_RAW = "raw" # change the name. before this was "aio"
DRIVER_TAP_QCOW2 = "qcow2" # add.
DRIVER_TAP_QCOW = "qcow"
DRIVER_TAP_COW = "cow" # add.
DRIVER_TAP_VMDK = "vmdk"
DRIVER_TAP_CLOOP = "cloop" # add.
DRIVER_TAP_DMG = "dmg" # add.
DRIVER_TAP_VPC = "vpc" # add.
> - Makes sure the disk image we create is using appropriate file format
> - Automatically choose the best driver type to match the disk type.
But I'm still not sure that how to choose the best driver format
automatically. Is it possible to choose that by the virtualization type
(i.e. xen, qemu, kvm, or kqemu) ?
> writing lots of zeros (non-sparse). The other formats like vmdk, qcow,
> etc have some special file structure that needs writing out. We could add
> code for doing this in python in virt-install, or we could simply run the
> 'qemu-img' command to create the file in non-raw case.
Well, I prefer using the "qemu-img" command.
More information about the et-mgmt-tools