Over a million developers have joined DZone.

Summer Project 2016: The CouchCase

DZone's Guide to

Summer Project 2016: The CouchCase

As the last part of the series on his summer project, CouchCase, Matthew Groves shares with us how he clustered Couchbase Server nodes. Read on to find out more.

· Database Zone
Free Resource

Learn how to move from MongoDB to Couchbase Server for consistent high performance in distributed environments at any scale.

I know that Summer 2016 is long gone, but I promised one more blog post about building the CouchCase. This part was the easiest, seeing as clustering Couchbase Server nodes together is really easy.


First, a little information about how I networked the Intel Compute Sticks. On the router in the CouchCase, I’ve pegged each network adapter to a specific IP address. How to do this is going to vary from router to router, so consult your manual.

Here’s a snapshot of STICK1, STICK2, and STICK3 all pegged to three IP addresses and attached to the router.

Compute sticks running Couchbase Server attached to a router


The first time you setup Couchbase Server, you are creating a cluster with a single node. So, if you’ve done this, as far as setting up an entire cluster, you are most of the way there.

Next, install Couchbase Server on another machine (or VM or whatever). Instead of selecting "Start a new Cluster", select "Join a cluster now." Enter the IP address of the first node you created, as well as the username/password information that you set it to be.

Join a Couchbase node to a Couchbase cluster

Once you do that, you should get a message saying "This server has been associated with the cluster and will join on the next rebalance operation."

A Couchbase node has been successfully joined to a Couchbase cluster

A rebalance operation is necessary for Couchbase to figure out all the details of which node a given document should live on. For more information, check out the documentation on Rebalancing a Cluster.

A rebalance is a background operation, and should not interfere with the operation of nodes that are already working. This means that if you need to add capacity to your database, you don’t have to take down your website or schedule a 'maintenence window' or anything like that.

Once the rebalance is complete, you should see a list of nodes:

List of nodes in a Couchbase cluster

And there you have it! The CouchCase is ready for the road. You've seen how to network and cluster your Couchbase Server nodes, as well as handle a few of the hiccups that can crop up along the way, such as rebalancing. That's all! Enjoy autumn.

Want to deliver a whole new level of customer experience? Learn how to make your move from MongoDB to Couchbase Server.

couchbase server ,couchbase ,database ,clusters

Published at DZone with permission of Matthew Groves, DZone MVB. See the original article here.

Opinions expressed by DZone contributors are their own.


Dev Resources & Solutions Straight to Your Inbox

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.


{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}