ORA-01591: lock held by in-doubt distributed transaction
If you got ” ORA-01591: lock held by in-doubt distributed transaction ” error, it means there are some uncommitted transactions in the database.
We need to perform rollback or commit force for Uncommitted transactions to solve this problem.
ORA-01591
You can query uncommitted or pending transaction with following script. This script will generate rollback force command also, so you can execute the result of following command.
SQL> select 'rollback force '''||local_tran_id||''';' from DBA_2PC_PENDING where state='prepared';
rollback force '72.6.1262301';
You can perform rollback related transaction with following command.
SQL> rollback force '72.6.1262301';
lock held by in-doubt distributed transaction
Following script will generate commit force command also, so you can execute the result of following command.
SQL> select 'commit force '''||local_tran_id||''';' from DBA_2PC_PENDING where state='prepared';
commit force '72.6.1262301';
You can perform force commit to related transaction with following command.
SQL> commit force '72.6.1262301';
No comments:
Post a Comment