[noSQL] Installing cluster Apache CouchDB with BigCouch on Ubuntu server

BigCouch is an open source, highly available, fault-tolerant, clustered & API-compliant version of Apache CouchDB.
BigCouch allows users to create clusters of CouchDBs that are distributed over an arbitrary number of servers. While it appears to the end-user as one CouchDB instance, it is in fact one or more nodes in an elastic cluster, acting in concert to store and retrieve documents, index and serve views, and serve CouchApps.
In this document, I setup on bigcouch-ckl001.local and bigcouch-ckl002.local (nslookup completed)
Step 1. Setup Bigcouch
Debian:
sudo apt-get install lsb-release
echo "deb http://packages.cloudant.com/debian `lsb_release -cs` main" | sudo tee /etc/apt/sources.list.d/cloudant.list
sudo apt-get update
sudo apt-get install bigcouch
Ubuntu:
echo "deb http://packages.cloudant.com/ubuntu `lsb_release -cs` main" | sudo tee /etc/apt/sources.list.d/cloudant.list
sudo apt-get update
sudo apt-get install bigcouch
Step 2. Configuring your nodes:
sudo nano /opt/bigcouch/etc/vm.args
On bigcouch-ckl001.local
-name bigcouch@bigcouch-ckl001.local
-setcookie chungkol123
On bigcouch-ckl002.local
-name bigcouch@bigcouch-ckl002.local
-setcookie chungkol123
Step 3. Restart bigcouch
sudo sv restart bigcouch
Step 4. Joining a node to a cluster
On bigcouch-ckl001.local
curl -X PUT http://localhost:5986/nodes/bigcouch@bigcouch-ckl002.local -d {}
On bigcouch-ckl002.local
curl -X PUT http://localhost:5986/nodes/bigcouch@bigcouch-ckl001.local -d {}
Step 5. Loging
tail -f /opt/bigcouch/var/log/bigcouch.log
Learn more: http://bigcouch.cloudant.com/use