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-
actionhigh-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 -zprocess_id to kill a database
serverprocess that is executing a piece of work being performed on
behalf of a global transaction.
Ineither case, if the piece ofwork 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 topage 9-30 for a summary
discussion. This section provides additional details. Turn toFigure 9-11 on
page 9-49 to seean 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
waitingfor instructions from the coordinator is blocked from completing its
transaction. During this time, the transaction remains open, the logical log
filescontaining 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
backa precommitted piece of work without the instruction or knowledge of
the coordinator.