There are some differences in how indoubt DRDA transactions are recovered as a result of the type of communications environment used.
Recovery of indoubt DRDA transactions at "downstream" DRDA 2 Application Servers (AS) is normally performed automatically by the Transaction Manager (TM) and the LU 6.2 Sync Point Manager (SPM) if in an SNA communications environment. An indoubt transaction at a DRDA 2 AS does not hold any resources at the local DB2 location but does hold resources at the AS as long the transaction is indoubt at the AS. If the AS determines that a heuristic decision must be made, then the AS administrator may contact the local DB2 database administrator (for example via telephone) in order to determine whether to commit or roll back the transaction at the AS. If this occurs, the LIST DRDA INDOUBT TRANSACTIONS command can be used to determine the state of the transaction at the local DB2. The following steps can be used as a guideline for most situations involving a SNA communications environment.
db2 => connect to db2spm Database Connection Information Database product = SPM0500 SQL authorization ID = CRUS Local database alias = DB2SPM
db2 => list drda indoubt transactions DRDA Indoubt Transactions: 1.db_name: DBAS3 db_alias: DBAS3 role: AR uow_status: C partner_status: I partner_lu: USIBMSY.SY12DQA corr_tok: USIBMST.STB3327L luwid: USIBMST.STB3327.305DFDA5DC00.0001 xid: 53514C2000000017 00000000544D4442 0000000000305DFD A63055E962000000 00035F
db2 => list drda indoubt transactions SQL1251W No data returned for heuristic query.then the transaction was rolled back.
There is another unlikely but possible situation that may occur. If an indoubt transaction with the proper luwid for the partner_lu is displayed, but the uow_status is "I" then the SPM doesn't know whether the transaction is to be committed or rolled back. The XID displayed in the message can be used to determine the proper commit decision as described in the "Manual Recovery of Indoubt Transactions" section.
Recovery of indoubt DRDA transactions involving TCP/IP communications environment has some differences to that for indoubt transactions involving a SNA communications environment. When an indoubt transaction occurs in a TCP/IP communications environment, an alert entry is generated at the client, at the database server, and/or at the the Transaction Manager (TM) database depending on who detected the problem. The alert entry is placed in the db2alert.log file. For more information on alerts, see the Troubleshooting Guide manual.
The resynchronization of any indoubt transactions occurs automatically as soon as the TM and the participating databases and their connections are all available again.
It is also possible to use the LIST INDOUBT TRANSACTIONS WITH PROMPTING command to support the heuristic operations such as heuristic forget, commit, and roll back. Tools can be written using the Database Monitor GET SNAPSHOT API sqlmonss() and the Transaction Heuristic API sqlxhqry(), sqlxfrg(), sqlxhcom(), and sqlxhrol() to perform these heuristic operations. For more information on these two APIs, see the System Monitor Guide and Reference for the first API and the API Reference for the second.