2010/3/17 Matthias Bolte <matthias.bolte(a)googlemail.com>:
2010/3/15 Daniel P. Berrange <berrange(a)redhat.com>:
> On Fri, Mar 12, 2010 at 09:19:02PM +0100, Matthias Bolte wrote:
>> diff --git a/tests/xml2vmxdata/xml2vmx-scsi-driver.xml
b/tests/xml2vmxdata/xml2vmx-scsi-driver.xml
>> new file mode 100644
>> index 0000000..797a26e
>> --- /dev/null
>> +++ b/tests/xml2vmxdata/xml2vmx-scsi-driver.xml
>> @@ -0,0 +1,25 @@
>> +<domain type='vmware'>
>> + <name>scsi-buslogic</name>
>> + <uuid>564d9bef-acd9-b4e0-c8f0-aea8b9103515</uuid>
>> + <memory>4096</memory>
>> + <os>
>> + <type>hvm</type>
>> + </os>
>> + <devices>
>> + <disk type='file' device='disk'>
>> + <driver name='buslogic'/>
>> + <source file='[datastore] directory/harddisk1.vmdk'/>
>> + <target dev='sda' bus='scsi'/>
>> + </disk>
>> + <disk type='file' device='disk'>
>> + <driver name='lsilogic'/>
>> + <source file='[datastore] directory/harddisk2.vmdk'/>
>> + <target dev='sdp' bus='scsi'/>
>> + </disk>
>> + <disk type='file' device='disk'>
>> + <driver name='lsisas1068'/>
>> + <source file='[datastore] directory/harddisk3.vmdk'/>
>> + <target dev='sdae' bus='scsi'/>
>> + </disk>
>> + </devices>
>> +</domain>
>
> Using the '<driver>' element here is somewhat incorrect, since this
> is in fact used to refer to the backend driver. The 'name' attribute
> refered to the host backend driver (only really used for xen to
> switch between kernel & userspace backends), while the 'type' refered
> to the file format (vmdk, qcow, etc).
>
> In the vmware context lsilogic/buslogic is refering to the guest
> device type.
>
> What is visible in the guest when you have 3 disks configured in this
> way with buslogic, lsilogic & lsisas1068 ? Do you get 3 separate PCI
> devices as the SCSI controllers & then 1 disk attached to each ? If
> so, then we could model this difference using the recent <controller>
> element instead.
>
> If there's only one PCI device / SCSI controller & different types of
> disk attached to that controller, then we'd need to invent a new way
> within <disk> of doing the model name
>
> Daniel
>
Yes, it's the SCSI controller device type. <driver name='buslogic'/>
currently maps to
scsi0.virtualDev = "buslogic"
and scsi0 is the first SCSI controller.
So I withdraw this patch and rework the controller type handling to
use the <controller> element.
There seems to be no documentation about the <controller> element on
the libvirt website, or do I miss something?
Matthias
As I already said your argument is valid, but I would like to push
this patch to get the problem with ESX4 and lsisas1068 [1] "fixed" for
the 0.7.8 release, because the reworked controller handling won't be
finished until 0.7.8.
[1]
https://www.redhat.com/archives/libvirt-users/2010-March/msg00016.html
Matthias