This information is only valid for CAST Dashboard ≥ 2.x
Introduction
If your CAST Dashboard service is unable to start, it may be due to a "locked" persistence schema (by default the persistence schema is called "cast_dashboards" and stores information about roles and data authorization). Schemas (and other database items) are usually "locked" while they are being updated, but sometimes the lock that is applied fails to be released correctly therefore preventing applications from accessing and updating the schema.
If your CAST Dashboard service fails to start, it could be due to a locked "cast_dashboards" schema.
How can I tell if my schema is locked?
Run the following query against the "cast_dashboards" schema:
SELECT * FROM cast_dashboards.databasechangeloglock WHERE cast_dashboards.databasechangeloglock.locked = true ORDER BY id ASC
How do I unlock the schema?
If the schema is locked, run the following query to unlock it - this will reset the data in the table:
UPDATE cast_dashboards.DATABASECHANGELOGLOCK SET LOCKED=false, LOCKGRANTED=null, LOCKEDBY=null WHERE ID=1;
You may need to re-run the query and increment the ID value if there is more than one lock recorded in the table.