Error : "500 internal error" on API call GET https://cloud.example.com/cloudapi/1.0.0/externalNetworks/{externalNetworkId}/usedIpAddresses
search cancel

Error : "500 internal error" on API call GET https://cloud.example.com/cloudapi/1.0.0/externalNetworks/{externalNetworkId}/usedIpAddresses

book

Article ID: 399563

calendar_today

Updated On:

Products

VMware Cloud Director

Issue/Introduction

  • The API call GET https://cloud.example.com/cloudapi/1.0.0/externalNetworks/{externalNetworkId}/usedIpAddresses via API explorer or postman returns the error below:

    "500 INTERNAL_SERVER_ERROR."
  • In /opt/vmware/vcloud-director/log/container-debug.log the below error is shown:

    DATE TIME | ERROR    | pool-jetty-382934         | DefaultExceptionMapper         | Internal server exception | requestId=########-####-####-########c842,request=GET https://cloud.example.com/cloudapi/1.0.0/externalNetworks/urn%3Avcloud%3Anetwork%########-####-####-########38dd/us...,requestTime=1747649060852,remoteAddress=##.##.##.##:65190,userAgent=Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/5...,accept=application/json;version 39.1
    java.lang.NullPointerException
            at com.vmware.vcloud.networking.dao.helper.AllocatedIpAddressDao.convertGatewayAssignedIpToUsedIpAddress(AllocatedIpAddressDao.java:862)
            at com.vmware.vcloud.networking.dao.helper.AllocatedIpAddressDao.convertEdgeGatewayOrNetworkAssignedIp(AllocatedIpAddressDao.java:835)
            at com.vmware.vcloud.networking.dao.helper.AllocatedIpAddressDao.lambda$convertToUsedIpAddressList$5(AllocatedIpAddressDao.java:811)
            at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:195)
            at java.base/java.util.LinkedList$LLSpliterator.forEachRemaining(LinkedList.java:1239)

Environment

VMware Cloud Director 10.6

Cause

The reason we are seeing the Internal Server error due to Null Pointer Exception is because there is no gateway_logical_resource entry for one of the gateways for which we are getting the assigned IP information.

Resolution

This needs database modification. Contact Broadcom Support and note this Article ID (399563) in the problem description.