This page will help you with a solution, if your snapshot/consolidation is failing and the below mentioned errors on table, <table-name> are found in the Cast-MSx.log.txt file.
ERROR: deadlock detected Détail : Process 24832 waits for AccessExclusiveLock on relation 24088 of database 12002; blocked by process 10660. Process 10660 waits for AccessShareLock on relation 24099 of database 12002; blocked by process 24832. Indice : See server log for query details. Où : SQL statement "truncate table <Table name>" PL/pgSQL function <function name>(integer) line 9 at SQL statement org.postgresql.util.PSQLException:ERROR: deadlock detected
As we can see in the logs, a deadlock has been encountered on the database which has forced the snapshot to fail.
A deadlock is created when two applications are each locking the data needed by the other, resulting in a situation when neither application can continue execution.
Release | Yes/No |
---|---|
8.3.x | |
8.2.x | |
8.1.x | |
8.0.x |
RDBMS | Yes/No |
---|---|
Oracle Server | |
Microsoft SQL Server | |
CSS3 | |
CSS2 |
- Package the source code and run the snapshot.
- Consult the CAST Dashboard at the same time while a new snapshot/consolidation is being generated involving the same local and central bases.
- The snapshot crashes with deadlock error in CAST-ms log file.
This situation may arise if we consult the CAST Dashboard at the same time while a new snapshot is being generated or consolidation of snapshot involving the same local and central bases.
Since some of the central tables are used while using the dashboard and during the generation of the snapshot\consolidation, a deadlock is encountered on the table if both actions are being performed at the same time.
This results in snapshot failure.
The solution would be to
- Check with the customer and advise them not to consult the CAST Dashboard while a new snapshot is being generated.
NOTE: It is strongly recommended to avoid consulting the CAST Dashboard while a new snapshot is being generated.
This recommendation is documented here.
Snapshot fails