Delete a Replication
Deleting an XDCR replication stops the replication of data, and removes the defined replication from Couchbase Server.
Proceed as follows:
Access Couchbase Web Console. Left-click on the XDCR tab, in the left-hand navigation menu.
This displays the XDCR Replications screen. The lower part of the main panel, entitled Remote Clusters, features and Ongoing Replications panel that currently has the following appearance:
This features information on a single, currently defined replication. In the
statuscolumn, this replication is shown to be
To delete the replication, left-click on the
Deletetab, which appears near the right-hand side of the row:
The following confirmation dialog is now displayed:
Left-click on Delete Replication, to confirm. The Ongoing Replications panel now reappears, showing no replications:
The replication has now been deleted.
From the starting-point defined above, in Examples on This Page, use the
xdcr-replicate command to delete an XDCR replication as follows.
couchbase-cli xdcr-replicate -c 10.142.180.101 \ -u Administrator \ -p password \ --delete \ --xdcr-replicator=570d0ca2db3b1e128e2fafd362a1bfd4/travel-sample/travel-sample
The value specified for the
--xdcr-replicator flag is that retrieved by means of the
--list flag, shown in Pause an XDCR Replication with the CLI.
--delete flag signifies that the replication is to be deleted.
If successful, the command returns the following:
SUCCESS: XDCR replication deleted
From the starting-point defined above, in Examples on This Page, use the REST API to delete an XDCR replication as follows.
curl -X DELETE -u Administrator:password \ http://10.142.180.101:8091/controller/cancelXDCR/570d0ca2db3b1e128e2fafd362a1bfd4%2Ftravel-sample%2Ftravel-sample
Note the encoded form of the endpoint, which is required.
This consists of the
id, the name of the source bucket, and the name of the target bucket.
These were obtained in Pause an XDCR Replication with the REST API.
If successful, no output is displayed. The replication has been deleted.
Once a replication has been deleted, you may also wish to delete the reference on which it was based. See Delete a Reference.