Test Environment:
VMware vCenter version: 5.1
Image: Sparse + ide
Log:
-------
2014-08-07 07:49:18.949 25720 WARNING nova.virt.vmwareapi.driver [-] Task [CopyVirtualDisk_Task] (returnval){
value = "task-4469"
_type = "Task"
} status: error A specified parameter was not correct.
fileType
2014-08-07 07:49:18.950 25720 WARNING nova.virt.vmwareapi.error_util [-] Fault InvalidArgument not matched.
2014-08-07 07:49:18.950 25720 ERROR nova.compute.manager [req-8f4578d9-834d-4e4d-a309-f4d117cc7a13 None] [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] Instance failed to spawn
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] Traceback (most recent call last):
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] File "/usr/lib/python2.6/site-packages/nova/compute/manager.py", line 2111, in _build_resources
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] yield resources
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] File "/usr/lib/python2.6/site-packages/nova/compute/manager.py", line 1997, in _build_and_run_instance
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] block_device_info=block_device_info)
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] File "/usr/lib/python2.6/site-packages/nova/virt/vmwareapi/driver.py", line 643, in spawn
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] admin_password, network_info, block_device_info)
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] File "/usr/lib/python2.6/site-packages/nova/virt/vmwareapi/vmops.py", line 399, in spawn
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] copy_spec)
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] File "/usr/lib/python2.6/site-packages/nova/virt/vmwareapi/vm_util.py", line 1312, in copy_virtual_disk
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] session._wait_for_task(vmdk_copy_task)
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] File "/usr/lib/python2.6/site-packages/nova/virt/vmwareapi/driver.py", line 1013, in _wait_for_task
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] ret_val = done.wait()
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] File "/usr/lib/python2.6/site-packages/eventlet/event.py", line 120, in wait
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] return hubs.get_hub().switch()
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] File "/usr/lib/python2.6/site-packages/eventlet/hubs/hub.py", line 187, in switch
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] return self.greenlet.switch()
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] VMwareDriverException: A specified parameter was not correct.
2014-08-07 07:49:18.950 25720 TRACE nova.compute.manager [instance: 069fc3ba-52cd-44fe-9035-7551d70f2daf] fileType
---------
The following code causes this issue. When disk_type is 'sparse' and adapter_type is 'ide' copy_spec will be set as None.
API CopyVirtualDisk_Task: If destSpec not specified, a preallocated format and 'busLogic' adapter type is assume. So adapter_type is force modified from 'ide' to 'busLogic'.
----from vmops.py
if not is_iso and disk_type == "sparse":
# Copy the sparse virtual disk to a thin virtual disk
disk_type = "thin"
copy_spec = self.get_copy_virtual_disk_spec(client_factory,
adapter_type,
disk_type)
vm_util.copy_virtual_disk(self._session, dc_info.ref,
str(sparse_ds_loc),
str(upload_path_loc),
copy_spec)
---------------
Hi,
The copy operation invoke through VC is intentionally passed a null copy_spec. That in itself should not be the cause of the failure. Can you confirm the image you used in a monolithic sparse image. I tested with an ide sparse vmdk, and the embedded descriptor information (you can get that by doing head -20 mysparse.vmkd) reads:
KDM6
# Disk DescriptorFile t="no" "monolithicSpar se"
version=1
encoding="UTF-8"
CID=1e521528
parentCID=ffffffff
isNativeSnapsho
createType=
# Extent description
RW 524288 SPARSE "dsl-disk1.vmdk"
# The Disk Data Base
#DDB
ddb.adapterType = "ide"
This disk spawns fine for me.
I used the following to import the image: format= bare --is-public=True --property vmware_ adaptertype= "ide" --property vmware_ disktype= "sparse" < msp_ide.vmdk
glance image-create --name=msp_ide --disk-format=vmdk --container-
This is verified on upstream master code today. Please verify the image format and glance properties.
If the problem still persists, we may have to look into the VC/ESX logs to understand the root cause.