KB-1024 "Could not acquire change log lock. Currently locked by <user>" error thrown during application server startup

Symptoms

During application server startup, the following error is shown in the application server log:

Caused by: java.lang.IllegalStateException: liquibase.exception.LockException: 
    Could not acquire change log lock. Currently locked by XXXXXXXXX (XXXXXXX)

As a result of this error, the application server fails to start successfully.

Cause

The DATABASECHANGELOGLOCK table in the primary data source has not been updated with the release lock information, and the lock flag is enabled while the application server starts up.

This is a result of killing the application server.

Action

  1. Go to the primary database schema.
  2. Go to the database change log lock table - <PRIMARY_DB>.DATABASECHANGELOGLOCK
  3. Change the values to the following:        
    LOCKED = 0
    LOCKGRANTED = NULL
    LOCKEDBY = NULL
    

A sample query is provided below:

UPDATE [DATABASECHANGELOGLOCK] 
SET    [DATABASECHANGELOGLOCK].LOCKED = 0, 
       [DATABASECHANGELOGLOCK].LOCKGRANTED = NULL, 
       [DATABASECHANGELOGLOCK].LOCKEDBY = NULL 
WHERE  ID=1

Note: The above SQL is provided by Appian as a sample and may not run correctly in all supported relational databases. For database-specific syntax, please contact your database administrator.

Affected Versions

This article applies to all versions of Appian.

Last Reviewed: February 2017

Related
Recommended