Set the setting for Cross Datacenter Replication (XDCR).


The basic syntax is:

couchbase-cli setting-xdcr -c [host]:8091 -u [admin] -p [password] [options]     


Use this command to set various options for XDCR. See Cross Datacenter Replication (XDCR).


The following are the command options:

Table 1. setting-xdcr options
Options Description
--checkpoint-interval=[SECONDS] The intervals between checkpoints, 60 to 14400 seconds.
--worker-batch-size=[500] Doc batch size, 500 to 10000.
--doc-batch-size=[2048]KB Document batching size, 10 to 100000 KB.
--failure-restart-interval=[30] The interval for restarting a failed XDCR, 1 to 300 seconds.
--optimistic-replication-threshold=[256] Document body size threshold (bytes) to trigger an optimistic replication.
--source-nozzle-per-node=[1-10] The number of source nozzles per source node.
--target-nozzle-per-node=[1-100] The number of outgoing nozzles per target node.
--log-level=[Error|Info|Debug|Trace] Logging level.
--stats-interval=[MS] The interval (in milliseconds) for statistics updates.


Set the interval for restarting a failed XDCR to 30 seconds:

couchbase-cli setting-xdcr -c -u Administrator -p password \
--failure-restart-interval 200