IBM 000-8697 User Manual

Page of 702
9-36
IBM Informix OnLine Database Server Administrator’s Guide
Heuristic Rollback
Heuristic Rollback
Two conditions might initiate a heuristic rollback:
The logical log fills to the point defined by one of the long-trans-
action high-water marks (configuration file parameters
LTXHWM
or
LTXEHWM
). The source of the long-transaction condition is a piece of
work being performed on behalf of a global transaction.
An administrator executes tbmode -z process_id to kill a database
server process that is executing a piece of work being performed on
behalf of a global transaction.
In either case, if the piece of work has already sent a “can commit” message
to its coordinator, the action is considered a heuristic decision. If the coordi-
nator later decides that the transaction should be committed, the
consequence of the heuristic decision is a heuristic rollback.
If you require a general introduction to the concept of a heuristic rollback
within the two-phase commit protocol, refer to
 for a summary
discussion. This section provides additional details. Turn to
to see an illustration of the two-phase commit protocol for a piece
of work that is heuristically rolled back.
Condition 1: Logical Log Fills to a High-Water Mark
Under two-phase commit, a participant OnLine database server that is
waiting for instructions from the coordinator is blocked from completing its
transaction. During this time, the transaction remains open, the logical log
files containing records associated with the open transaction cannot be freed,
and the logical log continues to fill.
If the logical log fills to the value of the long-transaction high-water mark
(
LTXHWM
) while the participant is waiting, tbinit directs all database server
processes that own long transaction to begin rolling them back. If a piece of
work that is precommitted is the offending long transaction, tbinit has
initiated a heuristic rollback. That is, this OnLine database server is rolling
back a precommitted piece of work without the instruction or knowledge of
the coordinator.