Home | Previous Page | Next Page   Appendix A. Command-Line Utility Reference >

cdr start replicate

The cdr start replicate command starts the capture and transmittal of replication transactions.

Syntax

Read syntax diagramSkip visual syntax diagram>>-cdr start replicate--+-------------------------+------------->
                        |                    (1)  |
                        '-| Connect Option |------'
 
              .------------------.
              V                  |
>--repl_name----+--------------+-+------------------------------>
                '-server_group-'
 
>--+-------------------------------------------------------------------+-><
   '- --syncdatasource=data_server--+--------------------------------+-'
                                    '- --extratargetrows=-+-delete-+-'
                                                          +-keep---+
                                                          '-merge--'
 
Notes:
  1. See page Connect Option.
Element Purpose Restrictions Syntax
data_server The database server from which the data is copied to all other database servers listed The database server must be defined in Enterprise Replication.
repl_name Name of the replicate to start The replicate must exist. Long Identifiers
server_group Name of database server groups on which to start the replicate The database server groups must be defined for Enterprise Replication.

The following table describes the cdr start replicate options.

Long Form Short Form Meaning
--extratargetrows= -e Specifies how to handle rows found on the target servers that are not present on the data source server from which the data is being copied (data_server):
  • delete: (default) remove rows and dependent rows, based on referential integrity constraints, from the target servers
  • keep: retain rows on the target servers
  • merge: retain rows on the target servers and replicate them to the data source server
This option applies to the initial data synchronization operation only; it does not affect the behavior of the replicate.
--syncdatasource= -S Specifies the name of the database server to use as the reference copy of the data. This server is started even if it is not listed as one of the servers to start.

Usage

The cdr start replicate command causes the replicate to enter the active state (capture-send) on the specified database servers and the source database server specified by the --syncdatasource option. If no server is specified, the repl_name starts on all servers that are included in the replicate. A replicate can have both active and inactive participants. When at least one participant is active, the replicate is active. You cannot start replicates that have no participants.

If a replicate belongs to an exclusive replicate set, you cannot run cdr start replicate to start that individual replicate. You must use cdr start replicateset to start all replicates in the exclusive replicate set.

Because Enterprise Replication does not process log records that were produced before the cdr start replicate command was run, transactions that occur during this period might be partially replicated. To avoid problems, either issue the cdr start replicatecommand on an idle system (no transactions are occurring) or use the BEGIN WORK WITHOUT REPLICATION statement until after you successfully start the replicate.

Examples

The following command starts the replicate accounts on the server groups g_svr1 and g_svr2:

cdr sta rep accounts g_svr1 g_svr2

See Also

Home | [ Top of Page | Previous Page | Next Page | Contents | Index ]