- 论坛徽章:
- 0
|
为什么回滚段在没有任务的时候,几乎被完全占用?
查了metalink
说是
FAILED DISTRIBUTED TRANSACTIONS
Before you begin, make note of the local transaction ID, <local_tran_id>;, from the error message reported.
1. Determine if you can attempt a commit or rollback of this
transaction. You can do the following select to help determine what
action to take:
SQL>; select state, tran_comment, advice from dba_2pc_pending
where local_tran_id = '<local_tran_id>;';
Review the TRAN_COMMENT column as this could give more information as to the origin of the transaction or what type of transaction it was. Review the ADVICE column as well. Many applications prescribe advice about whether to force commit or force rollback the distributed transaction upon failure. 2. Commit or rollback the transaction.
To commit:
SQL>; commit force '<local_tran_id>;';
To rollback:
SQL>; rollback force '<local_tran_id>;';
WARNING: Step 3 (purge_lost_db_entry) and Step 4 should ONLY be used when the other database is lost or has been recreated. Any other use may leave the other database in an unrecoverable or inconsistent state. 3. If your are using release 7.3.x or greater and you need to execute purge_lost_db_entry from the suggestions above
execute the following command in either Server Manager or SQL*Plus:
SQL>; execute sys.dbms_transaction.purge_lost_db_entry('<local_tran_id>;');
SQL>; COMMIT; NOTE: You must run above procedure as sys (since package is owned by sys),
you must have execute privileges, or have DBA privileges 4. If running a release below 7.3 but were suggested to execute purge_lost_db_entry :
Connect to Server Manager or SQL*Plus and execute the following
commands:
SQL>; connect sys/<password>;
SQL>; set transaction use rollback segment system;
SQL>; delete from dba_2pc_pending where
local_tran_id = '<local_tran_id>;';
SQL>; delete from pending_sessions$ where
local_tran_id = '<local_tran_id>;';
SQL>; delete from pending_sub_sessions$ where
local_tran_id = '<local_tran_id>;';
SQL>; COMMIT;
Solution Explanation:
=====================
The above steps work ONLY after verifying that the other database the Distributed Transaction is dependent on is no longer available. The steps above will allow these transactions to be deleted and no longer cause RECO to keep giving you the error messages stated in the problem. |
|