A Mirror Replication Agent instance can be in one of two discrete states:
Admin – allows you to set or change any Mirror Replication Agent configuration parameter. No replication processing occurs when the instance is in Admin state.
Replicating – indicates normal replication processing in the Mirror Replication Agent instance—scanning the transaction log, processing log records, and sending LTL commands to the Replication Server. When the state appears as Replicating (Waiting at end of log), the instance is idle and waiting for transactions to be logged, ready to continue replication processing when new transactions appear in the log.
The state of a Mirror Replication Agent instance can be changed by either:
An external event that occurs while the Mirror Replication Agent is processing transactions (for example, a network error on the Replication Server connection), or
Operator intervention (for example, invoking a command that changes the state).
From the time a state-changing event occurs until the moment the Mirror Replication Agent instance is actually in the new state, the instance is in state transition. During state transition, some Mirror Replication Agent commands (such as shutdown) are ignored.
A Mirror Replication Agent instance goes to Admin state when:
The instance is started in its default state.
The instance is started with the mra utility -admin option.
The Mirror Replication Agent quiesce or suspend command is invoked.
An unrecoverable replication error occurs while the instance is in Replicating state.
In Admin state, the Mirror Replication Agent instance is running, but it has no connection established to the Replication Server or the primary database.
You can perform most administrative tasks while the Mirror Replication Agent instance is in Admin state, including changing the value of any Mirror Replication Agent configuration parameter.
In Admin state, the instance can
open a connection to the primary database, if necessary to process
commands that request results from the primary database.
A Mirror Replication Agent instance may go to Admin state from Replicating state when a network failure or communication error causes its connection to the Replication Server to be dropped.
When Mirror Replication Agent drops a connection, before it goes to Admin state, it attempts to re-establish the connection using the values recorded in its configuration parameters for that connection. If its connection to the Replication Server cannot be restored, the Mirror Replication Agent instance goes to Admin state.
To go from Admin state to Replicating state, use the Mirror Replication Agent resume command. See “Starting replication in the Mirror Replication Agent” for more information.
In Replicating state, the Mirror Replication Agent instance maintains a connection to the Replication Server, and its Log Reader component scans the the mirror log devices for transactions to replicate.
Normally, when the Mirror Replication Agent instance is in Replicating state, it maintains a connection to the primary database to reserve the logscan context and update the secondary truncation point. If it drops the primary database connection (for example, because the primary database goes offline), Mirror Replication Agent logs the event and continues its normal replication processing.
There may be no replication throughput (that is, reading
transactions from the log and sending LTL commands to the Replication
Server) when the Mirror Replication Agent instance is in Replicating state.
In that event, the Mirror Replication Agent state may appear as Replicating
(Waiting at end of log).
To go from Replicating state to Admin state, you can use either the quiesce or suspend command. See “Stopping replication in the Mirror Replication Agent” for more information.