Site icon Database Tutorials

How To Install Couchbase Cluster with CLI

The purpose of our article is to install Couchbase Cluster via CLI. We can also install the cluster over the UI, but we will perform these operations over the CLI first.

As a first step, Couchbase Server must be installed on the servers where we will install Cluster. You can access the answer of how to install Couchbase Server from the below article.

“How To Install Couchbase Server on Ubuntu 16.04”

We have two servers whose couchbase installations have been completed and we will start with Cluster Initialize as a first step. Here we start operations on our first machine.

Cluster-Init Syntax

For our example, we prepare the script as follows.
NOTE: You should write the IP information of our Cluster server and the server we will add, instead of <IP_Address_Node_1> and <IP_Address_Node_2>.

We added Node to Cluster.

After adding node, we need to start Rebalance and activate the node in Cluster.

Rebalance syntax

For our example, we prepare the script as follows.

List couchbase clusters nodes

We will see our node list and their status.

Create Bucket

We use our bucket-create function.

Bucket-create syntax:

For our example, we prepare the script as follows.

 

Exit mobile version