Article - CS308548

After upgrade ThingWorx Platform with PostgreSQL fails to start with error "duplicate key value violates unique constraint"

Modified: 06-Nov-2023   


Applies To

  • ThingWorx Platform 8.2 to 9.3
  • PostgreSQL

Description

  • ThingWorx fails to start with any of the following errors logged in <ThingworxStorage>/logs/ApplicationLog.log following an upgrade:
    • ERROR: duplicate key value violates unique constraint "root_entity_collection_pkey"_ Detail: Key (name)=(StyleThemes) already exists
      ERROR: duplicate key value violates unique constraint "root_entity_collection_pkey"_ Detail: Key (name)=(NotificationDefinitions) already exists
      ERROR: duplicate key value violates unique constraint "root_entity_collection_pkey"_ Detail: Key (name)=(NotificationContents) already exists
      ERROR: duplicate key value violates unique constraint "root_entity_collection_pkey"_  Detail: Key (name)=(ThingGroups) already exists.
  • After the upgrade, URL not coming up with error related to database
  • After upgrade, ThingWorx Platform does not start with error in <Tomcat_home>/logs/catalina.out:
    • java.lang.Exception: Unable to initialize and start system: Could not create a transaction for ThingworxPersistenceProvider
  • ThingWorx is shutting down after upgrade with database error
  • In-place upgrade fails to launch ThingWorx
  • Upgraded and started the tomcat, we are getting the an error and Thingworx Platform is not getting started.
This is a printer-friendly version of Article 308548 and may be out of date. For the latest version click CS308548