How to Install Apache CouchDB 2.3.0 in Linux

Apache CouchDB is an open source document-oriented database with NoSQL – means, it doesn’t have any database schema, tables, rows, etc, that you will see in MySQL, PostgreSQL, and Oracle. CouchDB uses JSON to store data with documents, which you can access from a web browser via HTTP. CouchDB works smoothly with all latest modern web and mobile apps.

This article explains how to install Apache CouchDB 2.3.0 on RHEL, CentOS, Fedora, Debian and Ubuntu Linux distributions using the convenience binary packages.

Enabling the Apache CouchDB Package Repository

To install Apache CouchDB on CentOS and RHEL distributions, first you need to install and enable EPEL repository and update the system software packages to latest using following commands.

# yum update
# yum install epel-release

Next, on CentOS distribution, create a file called /etc/yum.repos.d/bintray-apache-couchdb-rpm.repo and place the following text into it.


On RHEL distribution, create a file called /etc/yum.repos.d/bintray-apache-couchdb-rpm.repo and place the following text into it. Make sure to replace the version number el7 or el6 in the file.

baseurl=$basearch/ gpgcheck=0 repo_gpgcheck=0 enabled=1

On Debian/Ubuntu distributions, run the following command to enable repository. Make sure to replace {distribution} with the appropriate choice for your OS version: Debian 8: jessie, Debian 9: stretch, Ubuntu 14.04: trusty, Ubuntu 16.04: xenial or Ubuntu 18.04: bionic.

$ echo "deb {distribution} main" | sudo tee -a /etc/apt/sources.list

Installing the Apache CouchDB Packages

On CentOS and RHEL distributions, issue the following command to install Apache CouchDB packages.

# yum -y install epel-release && yum install couchdb

On Debian/Ubuntu distributions, first you need to install the repository key, update the repository cache and install the Apache CouchDB packages.

$ curl -L | sudo apt-key add -
$ sudo apt-get update && sudo apt-get install couchdb

Configure the Apache CouchDB

By default, CouchDB runs on port 5984 and can be accessed within the server itself [localhost] only, if you would like to access it from the web, you need to modify the file /opt/couchdb/etc/local.ini and change the settings under [chttpd] section as shown below.

# vi /opt/couchdb/etc/local.ini
port = 5984
bind_address =

Next, go to the bottom of this file and define the admin user and password as shown.

admin = tecmint

Restart and enable the CouchDB service after making above changes.

# systemctl enable couchdb.service
# systemctl restart couchdb.service
# systemctl status couchdb.service

Verifying Apache CouchDB

Verify the CouchDB by going to the below URL http://your-ip-address:5984, there will see a Welcome page that displays the following message.

{"couchdb":"Welcome","version":"2.3.0","git_sha":"07ea0c7","uuid":"1b373eab0b3b6cf57420def0acb17da8","features":["pluggable-storage-engines","scheduler"],"vendor":{"name":"The Apache Software Foundation"}}

Next, visit Couchdb web interface at http://your-ip-address:5984/_utils/ to create and manage the Couchdb database.

Create Database in Couchdb

Create Database in Couchdb

For more information on how to create a database and manage their settings visit THIS PAGE, or stay tuned for our next series of articles on CouchDB.

If You Appreciate What We Do Here On TecMint, You Should Consider:

TecMint is the fastest growing and most trusted community site for any kind of Linux Articles, Guides and Books on the web. Millions of people visit TecMint! to search or browse the thousands of published articles available FREELY to all.

If you like what you are reading, please consider buying us a coffee ( or 2 ) as a token of appreciation.

Support Us

We are thankful for your never ending support.

Ravi Saive

I am Ravi Saive, creator of TecMint. A Computer Geek and Linux Guru who loves to share tricks and tips on Internet. Most Of My Servers runs on Open Source Platform called Linux. Follow Me: Twitter, Facebook and Google+

Your name can also be listed here. Got a tip? Submit it here to become an TecMint author.

RedHat RHCE and RHCSA Certification Book
Linux Foundation LFCS and LFCE Certification Preparation Guide
The Complete Linux System Administrator Bundle
Become an Ethical Hacker Bonus Bundle

You may also like...

10 Responses

  1. Wifi says:

    When using fix it to create an admin it does nothing, any ideas?

  2. mj says:

    add gcc-c++ to yum install for spidermonkey

  3. DMan says:

    Your title, “Install Apache CouchDB 1.6.1 on RHEL/CentOS/Fedora and Debian/Ubuntu”, is misleading in two very important ways. First you state that this is an “Install”. It is not. It is a *recompile of source code* and *install from source* (i.e. “make install”). If this were just an “install” on RHEL-derived distributions, it would be in RPM packages. And similarly, DEB packages for Debian-derived systems.
    Secondly, you state “…RHEL/CentOS…”. Then in the instructions, you say “…how to install CouchDB 1.6.1 on RHEL/CentOS 7/6…”. For someone looking to install CouchDB on a multitude of RHEL 5 systems, the title is misleading.

  4. Bill Stephenson says:

    Hi Ravi,

    Thank you very much for sharing this. I used your install instructions on an inmotion hosting VPS running CentOS 6.11 after finding no joy trying those at the CouchDB website.

    The only thing I’d add is telling users how to get to the Fauxton DB manager:


    Thank you again!!

  5. Gokul says:

    Well documented and worked without any glitches, except i need to install the latest SpiderMonkey instead of the one listed here.
    I used after noticing the error below, when i ran ./configure on apache-couchdb.

    ‘configure: error: Could not find the jsapi header.’

    Switching to the new version of SpiderMonkey fixed the above problem.
    Thanks for writing this!

  6. Hi Ravi,
    Nicely laid out article, thanks for sharing.

    Just as a heads up though; having run the CouchDB instance from EPEL (and a few other sources) i was quite frustrated with running a seriously old version – Erlang included!

    I published an article on how to package a standalone RPM for CentOS 6 which you might find useful? This will package the CouchDB version of your choice, along with an Erlang version of your choosing:

    Thanks again!

  1. February 22, 2013

    […] you have RHEL / CentOS / Fedora, I came across this great set of instructions that uses Fedora’s EPEL repository to make installing couchdb a simple single invocation of […]

  2. February 24, 2016

    […] NoSQL database (NoSQL means it doesn’t provide any tables, rows, etc.) system much like Apache CouchDB. It stores data in JSON-like documents with dynamic schema’s for better […]

Got something to say? Join the discussion.

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.