A System Administrator does not see a VM get imported when trying to restore and re-import a VM to Cloud Director after deleting the original VM from Cloud Director and vCenter
The VM is in the vCenter Inventory, and Cloud Director detects it through the cell management import debug command (/opt/vmware/vcloud-director/bin/cell-management-tool debug-auto-import --org <org> --vm <vm_name>).
The VM is clearly in the right resource pool within vCenter for the Cloud Director's Data Center, but it does not show up in the Data Centers > Virtual Machines tab.
Cloud Director 10.6
This may happen for a number of mismatched state expectations in Cloud Director. One such cause might be that the VM was powered on before it was detected by Cloud Director during an inventory refresh.
It is best to follow the process outlined below to try and get Cloud Director to properly detect and import the virtual machine into management.
In vCenter:
1. Shut the VM down.
2. Note the storage location of the virtual machine and remove the virtual machine from inventory.
3. Add the virtual machine back to the inventory from the previously noted storage location. NOTE: Leave the virtual machine powered off.
This will get a new moref for the virtual machine.
In Cloud Director:
1. After adding the virtual machine back to the vCenter Inventory, do a vCenter Refresh under the Provider Portal's Resources > Infrastructure Resources > vCenter Server Instances tab.
2. The Import of the virtual machine should begin and finish now.
3. Use the Tenant Portal's Data Centers > Virtual Machines tab as a System Admin to manage the virtual machine as desired after the import finishes.
In Cloud Director 10.6, this KB outlines there is a bug in the cell management tool debug import command which erroneously shows the VM as not in a resource pool managed by Cloud Director even when it is, please see Virtual machine is present in a resource pool (resgroup-xxxxx) not managed by vCD.
Example:
/opt/vmware/vcloud-director/bin/cell-management-tool debug-auto-import --org <org> --vm <vm_name>
VM with name:<vm_name>, moref vm-###### in VC <vcenter> can be skipped for the following reasons:
1) Virtual machine is present in a resource pool (resgroup-######) not managed by vCD.