In this article, we will have explained the necessary steps to install Apache CouchDB on CentOS 7. Before continuing with this tutorial, make sure you are logged in as a user with sudo privileges. All the commands in this tutorial should be run as a non-root user.
Apache CouchDB is a free software resource that allows us to access data from where necessary by defining the Couch Replication Protocol, which was implemented by a variety of projects and products that cover all IT environments, from globally distributed server clusters, or mobile phones to web browsers.
Install Apache CouchDB on CentOS 7
Step 1. The first command will update the package lists to ensure you get the latest version and dependencies.
sudo yum install epel-release sudo yum update
Step 2. Install CouchDB on CentOS.
We must first add the Apache repository, use nano to open a file at the following path, and add the contents below:
sudo nano /etc/yum.repos.d/bintray-apache-couchdb-rpm.repo
[bintray--apache-couchdb-rpm] name=bintray--apache-couchdb-rpm baseurl=http://apache.bintray.com/couchdb-rpm/el$releasever/$basearch/ gpgcheck=0 repo_gpgcheck=0 enabled=1
Now that the repository is enabled, you can install the CouchDB packages using the following command:
yum install couchdb
After the installation finishes, we will start the service and enable it to run at the start of the system:
sudo systemctl start couchdb sudo systemctl enable couchdb
Step 3. Enable Fauxton Web GUI Administration Panel.
Fauxton is a web-based interface built into CouchDB. It provides a basic interface with the ability to manage documents, views, and various configuration settings:
sudo nano /opt/couchdb/etc/local.ini
Go to the ‘[chttpd]’ line and change the bind_address value with your server’s IP address:
[chttpd] ; These settings affect the main, clustered port (5984 by default). port = 5984 bind_address = 192.168.8.1
Restart CouchDB so the changes will take effect:
sudo systemctl restart couchdb
Now you can open your browser and see your Domain or public IP address through it like below:
Congratulation, you have learned how to install Apache CouchDB on CentOS 7. If you have any questions, please leave a comment below.