Resynchronization occurs if two-phase commit processing is interrupted by a resource failure. A resource failure may be caused by a node failure, a session failure, a program failure or other problems by a protected resource manager. The resource failure may be between a sync point manager and local resource managers or sync point manager and remote resource managers.
Resynchronization is conducted independently for each failed protected resource for which it is required. Resynchronization has the following purposes:
After an LU failure, it is possible that the partner that is responsible for resync is unable to establish the resync conversation because the failed LU has not been restarted. The responsible LU retries the resync at implementation-defined intervals.
In order to reduce the delay for resynchronization after an LU is restarted, the partner LU may signal to the resync initiator that it is available by sending an Exchange Log Names GDS variable that is not accompanied by a Compare States GDS variable. 2 Once the responsible LU has received this signal that the failed LU is active, it can initiate resync, sending the Exchange Log Names and Compare States GDS variables.
Sending the Exchange Log Names GDS variable as a signal of LU availability need be done only once, no matter how many protected conversations require resynchronization between the two LUs. Also, if the LU that becomes available is responsible for initiating resync for some conversations, it need not send another Exchange Log Names GDS variable as a signal that the LU is available, since the partner SPM can infer that a partner is available from the other resyncs the partner SPM initiates.
In the VSE environment, resynchronization has two components:
If there is a failure of the APPC session with the source system during the in-doubt period, the CICS/VSE syncpoint manager makes a heuristic decision based on the INDOUBT 4 option of the AXE transaction definition.
The details of what the task-related user exit does when it receives the
operation code from the CICS/VSE Syncpoint Manager during task-related user
exit resynchronization are shown in Table 33.
Table 33. Actions by the DRDA task-related user exit during task-related user exit resynchronization
CICS/VSE Syncpoint Manager operation code received by TRUE | DRDA task-related user exit actions | ||
---|---|---|---|
Backout (UERTBACK) | Issues EXEC SQL ROLLBACK to resource manager | ||
Committed (UERTCOMM) | Issues EXEC SQL COMMIT to resource manager | ||
Lost due to CICS cold start (UERTDGCS) | Generates a message indicating that the LUW is lost due to CICS cold
start:
ARI0193E The CICS log does not contain information for an in-doubt logical unit of work belonging to server server_name. Instructs the operator to FORCE the LUW if the LUW has an agent assigned to it (for example, the LUW has not been FORCED): ARI4018A Use the database manager SHOW and FORCE commands to commit or rollback the following units of work: ARI4019I SERVER_NAME = server_name. USER ID = user id. AGENT IDENTIFIER = N. Instructs the operator to RESET INDOUBT if the LUW does not have an agent assigned to it (for example, the LUW has been FORCED): ARI0195A Use the database manager SHOW INDOUBT operator command to find the following units of work: ARI0196I SERVER_NAME = server_name. RECOVERY TOKEN = rectok. | ||
LUW should not be in doubt (UERTDGNK) | Generates a message indicating that the LUW should not be in doubt:
ARI0194E A logical unit of work that the database manager for server server_name indicated needed to be resolved was not identifed by the CICS/VSE log as needing resolution. Instructs the operator to FORCE the LUW if the LUW has an agent assigned to it (for example, the LUW has not been FORCED): ARI4018A Use the database manager SHOW and FORCE commands to commit or rollback the following units of work: ARI4019I SERVER_NAME = server_name. USER ID = user id. AGENT IDENTIFIER = N. Instructs the operator to RESET INDOUBT if the LUW does not have an agent assigned to it (for example, the LUW has been FORCED): ARI0195A Use the database manager SHOW INDOUBT operator command to find the following units of work: ARI0196I SERVER_NAME = server_name. RECOVERY TOKEN = rectok. | ||
|
The DB2 Server for VSE resource manager processes the SQL request it
received from the task-related user exit. The action it takes is
determined by the SQL request and the LUW state which it remembers.
These actions are shown in Table 34.
LUW state at DB2 Server for VSE | SQL request passed by task-related user exit | |||
---|---|---|---|---|
Rollback | Commit | |||
LUWID Not Found | Send normal completion reply indicating Backout state. DB2 Server
for VSE notifies operator with message:
ARI0183E The Sync Point Manager has asked to ROLLBACK this LUW but the database manager has no memory of it. ARI0196I SERVER_NAME = server_name. RECOVERY TOKEN = rectok. | Send normal completion reply indicating Committed state. DB2
Server for VSE notifies operator with message:
ARI0183E The Sync Point Manager has asked to COMMIT this LUW but the database manager has no memory of it. ARI0196I SERVER_NAME = server_name. RECOVERY TOKEN = rectok. | ||
Indoubt (Prepared) | Drive backout of resource and send normal completion reply indicating Backout state. | Drive commit of resource and send normal completion reply indicating Committed state. | ||
Heuristic Backout | Send normal completion reply indicating Backout state. | Send normal completion reply indicating Committed state. DB2
Server for VSE notifies operator with message:
ARI0184A The Sync Point Manager has asked to COMMIT this LUW but the FORCE command was previously used to ROLLBACK it. ARI0196I SERVER_NAME = server_name. RECOVERY TOKEN = rectok. In this case, the LUW will still appear when the SHOW INDOUBT command is executed. The LUW must be cleared using the RESET INDOUBT command. In addition, manual intervention is necessary to ensure that the LUW is in a consistent state at all sites where the LUW has been distributed. This may require intervention at this database manager, or possibly at another database manager. Manual intervention could mean manually fixing the data or possibly restoring an archive. | ||
Heuristic Committed | Send normal completion reply indicating Backout state. DB2 Server
for VSE notifies operator with message:
ARI0184A The Sync Point Manager has asked to ROLLBACK this LUW but the FORCE command was previously used to COMMIT it. ARI0196I SERVER_NAME = server_name. RECOVERY TOKEN = rectok. In this case, the LUW will still appear when the SHOW INDOUBT command is executed. The LUW must be cleared using the RESET INDOUBT command. In addition, manual intervention is necessary to ensure that the LUW is in a consistent state at all sites where the LUW has been distributed. This may require intervention at this database manager, or possibly at another database manager. Manual intervention could mean manually fixing the data or possibly restoring an archive. | Send normal completion reply indicating Committed state. | ||
|