Ubuntu 18.04 and CouchBase

Cris Ferreira Pires
2 min readJun 1, 2021

--

CouchBase Logo

Originally known as Membase, is an open-source, distributed (shared-nothing architecture) multi-model NoSQL document-oriented database software package optimized for interactive applications. These applications may serve many concurrent users by creating, storing, retrieving, aggregating, manipulating and presenting data.

So here we will be setting up a CouchBase cluster of 2 nodes (master and slave) using Oracle VM VirtualBox.

After installing Ubuntu we must update it.

sudo apt update -y && sudo apt upgrade -y && sudo apt autoremove -y

Istalling dependencies and couchbase.

sudo apt install ssh -y
sudo apt install curl lsb-release gnupg
curl -O https://packages.couchbase.com/releases/couchbase-release/couchbase-release-1.0-amd64.deb

Now we need to unpack couchbase:

sudo dpkg -i ./couchbase-release-1.0-amd64.deb

Now we clone the VM, and do the following on both machines.

ssh-keygen -t rsa -P ""
cat ~/.ssh/id_rsa.pub >> ~/.ssh/authorized_key

Now depending on the machine:

ssh-copy-id [other_machine_username]@[other_machine_ip]

Then we check the ips with.

ip addr

Now on the browser, and we can do this on the host machine. (Your actual computer) wich will make the process faster.

With ‘masterip’:8091 we can access the couchbase interface.

Couchbase Interface

Now we configure the server:

CouchBase Server Configuration Interface

After this we will be redirected to the dashboard we click on Servers on the left nav bar.

There we add the slave machine:

Couchbase Adding a server

Here we will put the ip of the second machine, the same username and password we used before.

Then we click rebalance to get it up.

Couchbase 2 servers up

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

--

--

No responses yet

Write a response