VMware Cloud Foundation 9.0.2.0
When adding a vCenter with wrong credentials and the Inventory Sync failed. You will need to retry the failed task with proper credentials. This step will add the vCenter properly and Status will be shown as Green.
However, the issue will appear when trying to add then same vCenter again without retrying the existing task which will add the same vCenter twice.
The following workaround will require to remove the environment where the vCenter duplicates are placed on, and still associated to VCF Aria Operations.
Note: Before performing the following procedure, ensure that you take snapshots of VCF Operations nodes and the Fleet Management appliance.
1. Disconnect Fleet Management from VCF Operations admin UI
2. SSH into Fleet Management appliance and enable Standalone Fleet Management UI with command:
touch /var/lib/vrlcm/UI_ENABLED3. Login into the Fleet Management UI https://<FDQN or IP address> with admin@local user
4. Goto the Fleet Management Swagger and search for the environment id which require to be deleted using Environment GET API.
GET /lcm/lcops/api/v2/environmentsor alternatively from the Fleet Management UI select the VCF Operations and in the browser url you will get the environment id.
5. Delete the VCF Operations with:
DELETE /lcm/lcops/api/v2/environments/{environmentId}
Payload
{
"controllerType": "string",
"deleteFromInventory": true,
"deleteFromVcenter": false,
"deleteLbFromSddc": true,
"deleteWindowsVMs": true
}6. Goto the Tasks and Retry with skip option for the failed Delete Environment Task
7. Goto the Deployment Target and delete the vCenters
8. Goto VCF Operation UI and reregister the Fleet Management
9. Goto the Deployment Target and add the vCenters
10. SSH into Fleet Management appliance and disable Standalone Fleet Management UI with command:
rm /var/lib/vrlcm/UI_ENABLED