Failed to find VDS(s) with source ID(s) [dvs-id dvs-id] in inventory, Cluster creation via API fails in SDDC Manager
search cancel

Failed to find VDS(s) with source ID(s) [dvs-id dvs-id] in inventory, Cluster creation via API fails in SDDC Manager

book

Article ID: 419626

calendar_today

Updated On:

Products

VMware SDDC Manager

Issue/Introduction

  • The cluster has been created in both SDDC Manager and vCenter Server; however, the cluster status is reported as "Error" in the SDDC Manager UI.

  • The vSphere Distributed Switch (vDS) is successfully created and visible within the vCenter inventory.

  • The cluster in vCenter Server is empty and does not contain any associated ESXi hosts.

  • The configuration status for the respective ESXi hosts is displayed as "Error" in SDDC Manager.

  • Following error snippets are observed in SDDC Manager at var/log/vmware/vcf/domainmanager/domainmanager.log
    YYYY-MM-DDTHH:MM:SS.011+0000 ERROR [vcf_dm,6920e815c829401a3fc24c69e851a586,3e7c] [c.v.e.s.o.model.error.ErrorFactory,dm-exec-18] [C9INIF] FAILED_TO_FIND_VDS_WITH_SOURCE_ID Failed to find VDS(s) with source ID(s) [dvs-<id>, dvs-<id>] in inventory

    com.vmware.evo.sddc.orchestrator.exceptions.OrchTaskException: Failed to find VDS(s) with source ID(s) [dvs-<id>, dvs-<id>] inventory

  • A vSphere Distributed Switch (vDS) entry exists in the SDDC Manager database but is not mapped to any active cluster. Validate the database state using the steps below:

         Connect to SDDC Manager via SSH as root, and connect to the platform database by running the following command.
      /usr/pgsql/13/bin/psql -h localhost -U postgres -d platform

         List the Distributed switch IDs from VDS table by running following query.
      select id from vds;
     
         List the distributed switch IDs mapped to the clusters.
       select vds_id from cluster_and_vds;

              Identify the VDS ID that exists in the vds table but is missing from the cluster_and_vds table. This unmatched ID represents the stale entry.

Environment

SDDC Manager 5.x

Cause

The SDDC Manager database contains a stale entry in the vDS (Virtual Distributed Switch) table. This entry is not mapped to any active cluster in the environment, causing validation failures during SDDC operations

Resolution

Note : Take a snapshot of the SDDC manager VM before performing these step. 

We need to delete the stale entry from vds table in the SDDC Manager database to resolve the issue. 

1. Connect to SDDC Manager database using the following command. 
  /usr/pgsql/13/bin/psql -h localhost -U postgres -d platform

2. Delete the stale entry post connecting to SDDC manager database. Run the following command to achieve the same. 
  delete from vds where id = "Stale_ID_Found_Earlier";

3. Restart the failed task. This should work as expected.