[one-users] cannot use a iso based cdrom in vmware

Carlos A. caralla at upv.es
Tue May 17 08:12:07 PDT 2011


Hi,

for generated domain:
----------------------cut here--------------------------------
<domain type='vmware'>
<name>one-566</name>
<vcpu>1</vcpu>
<memory>262144</memory>
<os>
<type arch='i686'>hvm</type>
</os>
<devices>
<disk type='file' device='cdrom'>
<source file='[standard] 566/images/iso'/>
<target dev='hda' bus='ide'/>
<driver name='raw'/>
</disk>
</devices>
</domain>
----------------------cut here--------------------------------

now I get the next error:

$ /srv/cloud/one/bin/tty_expect -u myadmin -p XXXXXX virsh -c 
gsx://myhost?no_verify=1 define /srv/cloud/one/var/566/deployment.0

error: Failed to define domain from /srv/cloud/one/var/566/deployment.0
error: internal error Image file for IDE cdrom 'hda' has unsupported 
suffix, expecting '.iso'

The files have been properly copied but in fact they have a name other 
than *.iso. What I have in the VMWare repository is

myadmin at myhost:/var/lib/vmware/VirtualMachines/566/images$ ls -l
total 4
drwxrwxrwx 2 myadmin myadmin 4096 2011-05-17 17:03 disk.0

As you can see cdrom file types are not properly copied.

It seems to be easy to find a workaround (just rename the file in case 
that it is a cdrom type), but also use the proper file name. But 
currently vmware files are transfered in a different way (they are 
stored into folders to deal with parted disk files).

Regards,
Carlos A.

El 17/05/2011 15:33, Tino Vazquez escribió:
> Hi Carlos,
>
> thanks for your feedback! This looks like a bug. Could you please try
> changing src/vmm/LibVirtDriverVMware.cc:
>
>     * add this include at the beginning
>
> #include<unistd.h>
>
>     * replace line 222 (file<<  "\t\t\t<source file='"<<  source<<
> "'/>"<<  endl;)  with the following:
>
>              file<<  "\t\t\t<source file=["<<   datastore<<  "] "<<
> vm->get_oid()
>                   <<  "/images/"<<  basename((char *)source.c_str())<<
>   "'/>"<<  endl;
>
>
> You will need to recompile ONE and restart it.
>
> If this works, please come back and I'll open a ticket and fix this
> issue in the repo.
>
> Regards,
>
> -Tino
>
> --
> Constantino Vázquez Blanco | dsa-research.org/tinova
> Virtualization Technology Engineer / Researcher
> OpenNebula Toolkit | opennebula.org
>
>
>
> On Tue, May 17, 2011 at 1:04 PM, Carlos A.<caralla at upv.es>  wrote:
>> A template like this
>>
>> -----------cut here-------------------
>>
>> NAME = vm-vmware
>>
>> VCPU    = 1
>> MEMORY = 512
>> OS = [ ARCH = "i686" ]
>>
>> DISK = [
>>         source = "/tmp/iso" ,
>>         target="hda",
>>         bus="ide",
>>         type="cdrom"
>> ]
>>
>> -----------cut here-------------------
>>
>> generates a deployment file like this one
>>
>> -----------cut here-------------------
>>
>> <domain type='vmware'>
>> <name>one-559</name>
>> <vcpu>1</vcpu>
>> <memory>524288</memory>
>> <os>
>> <type arch='i686'>hvm</type>
>> </os>
>> <devices>
>> <disk type='file' device='cdrom'>
>> <source file='/tmp/iso'/>
>> <target dev='hda' bus='ide'/>
>> <driver name='raw'/>
>> </disk>
>> </devices>
>> </domain>
>>
>> -----------cut here-------------------
>>
>> The problem is the line that states<source file='/tmp/iso'/>  while it
>> should state<source file='[datastore] path/to/iso'/>  or something like
>> that.
>>
>> I found that file "LibVirtDriverVMware.cc" does not generate the proper
>> datastore substitution, although ISO file is copied.
>>
>> Is there any way to make isos work in vmware?
>>
>> Regards
>>
>> _______________________________________________
>> Users mailing list
>> Users at lists.opennebula.org
>> http://lists.opennebula.org/listinfo.cgi/users-opennebula.org
>>




More information about the Users mailing list