VMware Cloud Director is no longer referencing the expected Virtual Machine in vCenter
search cancel

VMware Cloud Director is no longer referencing the expected Virtual Machine in vCenter

book

Article ID: 325587

calendar_today

Updated On:

Products

VMware Cloud Director

Issue/Introduction

  • VMware Cloud Director(VCD) no longer points to the correct Virtual Machine(VM) in vCenter.
  • Post cloning operations of a VM in vCenter, Cloud Director no longer references the correct VM.
  • Post using a 3rd Party solution to restore a VM in vCenter, Cloud Director now references the wrong VM.
  • Actions such as Power On/Off initiated in Cloud Director result in the wrong VM in vCenter being Powered On/Off.
  • You might need to extract cloud UUID of VMs because you are seeing VM UUID mismatches in VCD, which is causing scheduled backup failures.

Environment

VMware Cloud Director 9.x
VMware Cloud Director 10.x

Cause

  • This issue occurs when more than one VM with the same cloud.uuid existing within the inventory of vCenter.
  • The issue will only manifest when external actions are performed against the Cloud Director VM directly in vCenter or via 3rd Party Backup and Restore solutions.

Resolution

This is not an issue with VMware Cloud Director, but is as a result of external manipulation of Cloud Director objects.

To workaround the issue, see the Workaround section below.


Workaround:
To resolve this issue, you need to ensure that the cloud.uuid value is unique in vCenter, or removed completely from the VM you do not wish Cloud Director to manage.

To identify affected Cloud Director VMs, you can connect to the Cloud Director Database:
  1. SSH into the VCD Primary Cell and log in as root user.
  2. Connect to the VCD Database using the command:

    db

  3. And now run the following SQL.

    Note:
    Modification of the SQL below may be required to fit your unique scenario.

    select
    vmi.name,
    vm.creation_status,
    vmi.moref as VMINV,
    vm.moref as VM,
    cvm.vmmoref as CVM,
    vmi.cloud_uuid,
    --vmi.instance_uuid,
    vmi.vm_path_name as VMINV_DS,
    vm.location_path as VM_DS,
    vm.dstore_moref,
    dsi.vc_display_name
    from vm_inv
    inner join vm_inv vmi on vmi.cloud_uuid = vm_inv.cloud_uuid
    left join vm on vm.moref = vmi.moref
    left join computevm cvm on cvm.vmmoref = vmi.moref
    left join datastore_inv dsi on dsi.moref = vm.dstore_moref
    --where vm_inv.name like '%<Name of VM in vCenter>%'
    order by vmi.cloud_uuid;


    For information on removing the VM from Cloud Director's scope, see the Additional Information.

Additional Information

How to remove a virtual machine from Management in vCloud Director
https://knowledge.broadcom.com/external/article/320484