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

Carlos A. caralla at upv.es
Tue May 17 08:32:10 PDT 2011


Sorry,

I provided you with wrong information

----------------------cut here--------------------------------

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

----------------------cut here--------------------------------


$ ls -l /var/lib/vmware/VirtualMachines/567/images
total 738176
-rw-r--r-- 1 oneadmin oneadmin 755144704 2011-05-17 17:21 disk.0

In fact, the "disk.0" is the iso file. Now

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

provides an error that is not related to the cdrom file but to the fact 
that I am not providing a disk for the VM (I am just testing)

Now the problem is about the name of the file

Regards.

El 17/05/2011 17:16, Tino Vazquez escribió:
> Hi Carlos,
>
> Couple of questions:
>
>   * What are the contents of /var/lib/vmware/VirtualMachines/566/images/disk.0?
>
>   * I take it that /tmp/iso is a file, could you rename it to
> "something.iso" and try again?
>
> Regards,
>
> -Tino
>
> --
> Constantino Vázquez Blanco | dsa-research.org/tinova
> Virtualization Technology Engineer / Researcher
> OpenNebula Toolkit | opennebula.org
>
>
>
> On Tue, May 17, 2011 at 5:12 PM, Carlos A.<caralla at upv.es>  wrote:
>> 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