"org.hibernate.exception.GenericJDBCException: Cannot release connection - Cannot release connection - Uncaught underlying exception" error moving vApp between Organization VDCs
search cancel

"org.hibernate.exception.GenericJDBCException: Cannot release connection - Cannot release connection - Uncaught underlying exception" error moving vApp between Organization VDCs

book

Article ID: 320521

calendar_today

Updated On: 01-14-2025

Products

VMware Cloud Director

Issue/Introduction

Symptoms:

  • In VMware Cloud Director, when attempting to move a vApp to another Organization VDC, the following error is encountered:
    [UUID] org.hibernate.exception.GenericJDBCException: Cannot release connection - Cannot release connection - Uncaught underlying exception.

  • In the /opt/vmware/vcloud-director/logs/vcloud-container-debug.log, entries similar to the following are logged:
    org.hibernate.HibernateException: org.hibernate.exception.GenericJDBCException: Cannot release connection
            at com.vmware.vcloud.common.persist.Conversation.monitor(Conversation.java:583)

Environment

VMware Cloud Director 10.x
VMware Cloud Director for Service Provider 10.x

Cause

This is a known issue in VMware Cloud Director 10.3.X.
The issue is caused by how the application manages the DB connections.

Resolution

This is a known issue affecting VMware Cloud Director 10.3.X.

The issue is resolved in VMware Cloud Director 10.4.X, available at VMware By Broadcom Downloads.

If you cannot upgrade to VMware Cloud Director 10.4.X, please use the workaround specified in the Workaround section below.

Workaround:

  1. SSH to the primary cell of the Cloud Director cluster.
  2. Take a backup of the Cloud Director database before making any changes. For appliance based setup, please refer Backup and Restore of VMware Cloud Director Appliance.
  3. Run the following commands on the primary cell:
    • /opt/vmware/vcloud-director/bin/cell-management-tool manage-config -n jms.cluster.discoveryMechanism -v TABLE
    • /opt/vmware/vcloud-director/bin/cell-management-tool manage-config -n database.pool.jdbcInterceptors -v "com.vmware.vcloud.common.datasource.CustomJdbcInterceptor;com.vmware.vcloud.common.datasource.ConnectionStateInterceptor;com.vmware.vcloud.common.datasource.QueryTimeOutInterceptor(queryTimeout=20000)"
  4. Restart the Cloud Director service on all cells:
    systemctl restart vmware-vcd


Please note: When upgrading to VCD 10.4.X, these configurations will need to be removed.

To remove these configurations, please run the below commands to reset Cloud Director to the default settings:

  • /opt/vmware/vcloud-director/bin/cell-management-tool manage-config -n jms.cluster.discoveryMechanism -d
  • /opt/vmware/vcloud-director/bin/cell-management-tool manage-config -n database.pool.jdbcInterceptors -d