In a vCenter on vSAN environment, some virtual machines in vCenter may appear as disconnected after a combination of entering site maintenance mode and performing a force takeover operation on one site.
VMware vSAN 9.1 and future releases
Detailed steps:
Steps to Manually Register a Virtual Machine on an ESXi Host
.vmx files across the datastores. The following command lists the virtual machine names and corresponding paths in the vSAN datastore:find /vmfs/volumes/<DATASTORE_NAME>/ -name "*.vmx"
.vmx file path obtained in the previous step:vim-cmd solo/registervm /vmfs/volumes/<DATASTORE_NAME>/<VM_DIRECTORY>/<VM_NAME>.vmx
vim-cmd vmsvc/getallvms | grep -i <VM_NAME>
Vmid Name File Guest OS Version Annotation
1 vCLS-c6ac0142-d536-7c27-####-######### [] /var/run/crx/infra/vCLS-c6ac0142-d536-7c27-####-#########/vCLS-c6ac0142-d536-7c27-####-#########.vmx crxSys1Guest vmx-##
The Vmid value is displayed in the first column of the output.
vim-cmd vmsvc/power.on <Vmid>