VMware

This Question is Answered

1 "helpful" answer available (6 pts)
6 Replies Last post: Sep 9, 2009 2:31 AM by mblake4u  

ovftool --nodisks still creates .ovf file with disk information posted: Aug 31, 2009 8:43 AM

Click to view mblake4u's profile Novice 9 posts since
Feb 15, 2009

Hi All,

I'm using ovftool with the --noDisks option, but there still seems to be disk information in the .ovf file (see attachments).

I'm trying to import the virtual appliance on a ESXI 3.5 update 2 server, using VM Converter 4.0.1.

When I try and import the virtual appliance, I get the following error:

FAILED: Unable to download the OVF file 'http: //xxx.xxx.xxx.xxx/vm_ovf_backups/esxi-test-disk1.vmdk'.

I thought the --noDisks option would leave out any information relating to the disks - am I wrong?

Regards, Michael

Attachments:
Click to view klassenvmware's profile Enthusiast 15 posts since
May 25, 2009

Hi Michael,

You are right. OVF Tool behavior with this option is non-intuitive. The original intention of this option was simply to download a raw OVF descriptor for inspection from, e.g., an ESX host an discarding the disks, but I can see that in this scenario it would be nice if it removed the references to the disk in the OVF descriptor itself. For now you will have to remove the references by hand yourself. There are two ways you can do it:

  1. Either remove the element <File ovf:href="esxi-test-disk1.vmdk" ovf:id="file1" ovf:size="0"/> from the reference section and the attribute ovf:fileRef="file1" from the Disk element (this will import the OVF package without importing the data from the disk, but it will still create an empty disk),
  2. Or, remove the elements <File ovf:href="esxi-test-disk1.vmdk" ovf:id="file1" ovf:size="0"/>, <Disk ovf:allocationUnits="1073741824" ovf:capacity="5" ovf:capacityAllocationUnits="byte * 2^30" ovf:diskId="vmdisk1" ovf:fileRef="file1" ovf:format="http://www.vmware.com/interfaces/specifications/vmdk.html#streamOptimized" ovf:populatedSize="0"/> and the element <Item>
    <rasd:AddressOnParent>0</rasd:AddressOnParent>
    <rasd:ElementName>disk1</rasd:ElementName>
    <rasd:HostResource>ovf:/disk/vmdisk1</rasd:HostResource>
    <rasd:InstanceID>7</rasd:InstanceID>
    <rasd:Parent>3</rasd:Parent>
    <rasd:ResourceType>17</rasd:ResourceType>
    </Item> (this will import the OVF package without any reference to the disk).
  • Kristian
Click to view klassenvmware's profile Enthusiast 15 posts since
May 25, 2009
Hi Michael,

Have you tried to import the OVF package with OVF Tool? You should be able to use OVF Tool for that purpose. Depending on your setup you should be able to invoke ovftool <.ovf file> vi://<host name/ip>, and get what you want.

  • Kristian
Click to view klassenvmware's profile Enthusiast 15 posts since
May 25, 2009
Hi Michael,

You specify the datastore by using the option --datastore (or the shorthand -ds). Try ovftool --datastore=ESXi-vmdk-1 /esxi-test.ovf vi://111.111.111.111/ instead.

  • Kristian

Developer Social Media

Communities