Master master vs Master slave replication in couchbase

Hi All,
Please clarify the below.

  • Does couchbase support master slave replication?Meaning all the reads and writes goto same leader node and new leader get elected on node failure.This happens without sharding and all the data wil be in a single node. Does couchbase support this type of setup?

  • Does couchbase support multi master replication?Meaning reads and writes can happe nthrough multiple leader nodes…Or multimaster means there can be multiple leader data shards instead of multiple of full data nodes as masters?

Or couchbase support only one type of replication which is buckets replicate as vbuckets as shards and read write happen for same document through same shards and shards can spread across multiple data nodes.

Please elaborate more


Hi IIsuru,

I am assuming, the replication you have stated here refers to inter-cluster replication across clusters or datacenters.
Couchbase can be configured as both active-active (multi-master) or active- passive (single master taking active traffic) and passive cluster can be promoted to active for disaster recovery.

Please refer to this documentation for information and feel free to ask any follow-up questions.

Hi Chaitra
I was not referring to inter cluster or xdcr.I want to be clear about couchbase data nodes residing in a single cluster.
In a single cluster does it support multi master meaning same document can be read from different master nodes same time?

Also confirm the fact that sharding happens automatically that if there are multiple data nodes documents will be spreaded across nodes as shards that different data will be read by different shard master nodes.Even though there are different master nodes we cant call this master master replication because always same data will be read by the same shard master node.

My question is does couchbase support multiple master nodes for same document within a single couchbase cluster?

If not what are the other advantages of couchbase over mongodb considering single cluster?

Please clarify


It’s a good question.

Hi Rao! Welcome to the Couchbase Forums.

If you’d like to learn how Couchbase stores and replicates data, Understanding vBuckets is a good place to start.

As for the advantages of Couchbase over MongoDB, Compare Couchbase vs. MongoDB lists some of the highlights.

If you have more questions, feel free to start a new forum topic.