Hi,
I trying to Clone a VM, It works perfect when i specify host managed object Reference(MOR) in VirtualMachineRelocateSpec.
http://pubs.vmware.com/vi3/sdk/ReferenceGuide/vim.vm.RelocateSpec.html
When i try with Cluster managed object Reference (MOR) I'm getting this error "The request refers to an unexpected or unknown type."
// Get clone specifications
VirtualMachineRelocateSpec relocSpec = new VirtualMachineRelocateSpec();
relocSpec.datastore = targetDataStore;
relocSpec.pool = resourcePoolRootRef;
// assgining cluster compute resource pool...
relocSpec.host = hostParentCompResRef;
If i change it to Host it works fine...
relocSpec.host = hostRef;
I don't want to specify particular host, the Cluster is DRS enabled ....
Still I get this error can anyone help...
Anand.