Error: "The VMware Cloud Director entity com.vmware.vcloud.entity.network:########-####-####-####-############ does not exist" when making API calls to Cloud Director
search cancel

Error: "The VMware Cloud Director entity com.vmware.vcloud.entity.network:########-####-####-####-############ does not exist" when making API calls to Cloud Director

book

Article ID: 379808

calendar_today

Updated On:

Products

VMware Cloud Director

Issue/Introduction

  • Attempting to execute API calls to Cloud Director fail with an error of the form:

The VMware Cloud Director entity com.vmware.vcloud.entity.network:########-####-####-####-############ does not exist

  • The network with the UUID in the error is not visible in the Cloud Director UI.
  • The network with the UUID in the error can be seen in the Cloud Director database, logical_network table:

select * from logical_network where id = '########-####-####-####-############';

  • The network with the UUID in the error can be queried via the Cloud Director API:

GET https://{vcd_host}/cloudapi/1.0.0/externalNetworks/urn:vcloud:network:########-####-####-####-############

Environment

VMware Cloud Director 10.3.x

Cause

This issue can occur if the network with the UUID in the error has a REALIZATION_FAILED status.

Resolution

If the network is not in use it can be deleted from Cloud Director via the Cloud Director API.

Example steps would be as follows:

      1. Before making changes, backup the Cloud Director database as per the documentation Back Up the Embedded Database of Your VMware Cloud Director Appliance.
      2. Log in to the Cloud Director API as a System Administrator as outlined in KB article How to establish an API connection VMware Cloud Director.
      3. Using the UUID in the error message perform a Cloud Director API call to retrieve the network details, for example with Curl:

        curl -kv 'https://{vcd_host}/cloudapi/1.0.0/externalNetworks/urn:vcloud:network:########-####-####-####-############' -H 'Accept: application/json;version={vcd_api_version}' -H 'Content-Type: application/json' -H 'Authorization: Bearer {vcd_auth_token}'

      4. Confirm that the network is returned and that it has a REALIZATION_FAILED status and no IPs are in use:

        "status": "REALIZATION_FAILED",
        "networkBackings": null,
        ...
        "usedIpCount": 0,

      5. If the network is in a REALIZATION_FAILED status, is not in use, and we wish to delete it, this can be done via the Cloud Director API, for example with Curl:

        WARNING: This request with delete the network provided, please ensure the correct UUID is provided and that the network is not in use before proceeding.
        curl -kv -X DELETE 'https://{vcd_host}/cloudapi/1.0.0/externalNetworks/urn:vcloud:network:########-####-####-####-############' -H 'Accept: application/json;version={vcd_api_version}' -H 'Content-Type: application/json' -H 'Authorization: Bearer {vcd_auth_token}'

      6. Confirm a network delete task is started and that it completes successfully. Once the network is deleted the issue should be resolved.