Syncing a Catalog in Content Library fails with error " java.lang.NullPointerException"
search cancel

Syncing a Catalog in Content Library fails with error " java.lang.NullPointerException"

book

Article ID: 375644

calendar_today

Updated On:

Products

VMware Cloud Director

Issue/Introduction

Unable to sync a catalog in vCloud Director

Environment

vCloud Director 10.x

Cause

This might happen due to a stale entry in the vCD DB for the problematic Catalog

Resolution

NOTE: This needs DB update intervention. Please make sure to take valid VCD snapshot or database backup

Database backup can be taken by running below queries on VCD primary cell :

  • Navigate to bin directory: cd /opt/vmware/appliance/bin/
  • Run query to intiate backup : ./create-backup.sh

1. Login to VCD Database following the steps outlined below:

su - postgres  and then run psql vcloud 
    
2. Run the following query to check for the deleted item:
    select * from catalog where name='<catalog_name>';   (Note the catalog_id from this query)

3. Run the delete query to clear up all the pending execution for the problematic Catalog
    delete from catalog_item where id='<xxxx.xxxx.xxxxx>'; ID taken from step 2

Refresh the VCD GUI and intiate the sync manually.