Rebuilding queues from off-line database logs

This task is used to recover data from off-line database logs. You use the rebuild queues command only after you have restarted the Replication Server in standalone mode. For details on standalone mode, see “Using standalone mode”. Executing rebuild queues in standalone mode puts Replication Server in recovery mode.

In recovery mode, the Replication Server allows only RepAgents in recovery mode to connect. If a RepAgent that is not in recovery mode attempts to connect, Replication Server rejects it with following error message:

Rep Agent not in recovery mode

If you use a script that automatically restarts RepAgent and connects it to the Replication Server, you must start RepAgent using the for_recovery option. RepAgents are not allowed to connect in normal mode.

Figure 7-2 illustrates the progression from normal mode to standalone mode to recovery mode using the rebuild queues command.

Figure 7-2: Entering recovery mode with the rebuild queues command


Using standalone mode

To start Replication Server in standalone mode, use the -M flag. Standalone mode is useful for looking at the state of Replication Server because the state is static. Standalone mode allows you to review the contents of the stable queues because no messages are being written to or read from the queues.

Standalone mode differs from Replication Server’s normal mode in the following ways: