Debian is very known to be a robust system. Not in vain is the basis of many other Linux distributions and many subsystems. So Debian is the ideal Linux distribution for the storage of scalable data. In this sense, we are presented with several database managers oriented to their scalability. For that reason, in this post, I will teach you how to install CouchDB in Debian 9 so that you have a professional database manager with community support.
CouchDB is a database manager for the web. It takes care of saving and storing NoSQL type data for server-side applications. It is widely used and its learning curve is very low.
On the other hand, CouchDB places a lot of emphasis on data replication as a persistent way to obtain data. That is, we will be able to connect multiple nodes and from there do the replication.
Of course, there are a lot of features and reasons why this project of the Apache Foundation is so important today.
So, let us start.
Install CouchDB on Debian 9
The application is available to be installed on various operating systems. Obviously, Linux has prepared installers. Even for Debian 9, there is a package repository of its own. This facilitates the installation of CouchDB quite a bit since we can do it from APT.
It is recommended that you read our post about APT.
So the first step is to connect to your server and run this command as root:
:~# echo "deb https://apache.bintray.com/couchdb-deb stretch main" | tee -a /etc/apt/sources.list deb http://apache.bintray.com/couchdb-deb stretch main
Next, you have to import the GPG key for the repository.
:~# curl -L https://couchdb.apache.org/repo/bintray-pubkey.asc | apt-key add - OK
image
Next, install CouchDB on Debian 9 by running the following command:
:~# apt update :~# apt install couchdb
During the installation, you will have to configure some things. First of all, you need to know if it is for a single node or for a cluster.
Then, you will have to define the IP address where the instance will be accessed. If you set 0.0.0.0 you will be able to access from any IP address.
And finally, define a root password.
So, that is it. Let us test it.
Testing CouchDB
The best way to test if everything went well is to access the CouchDB web GUI. For this, it is necessary that in your firewall you have opened port 5984. In case you use UFW you could do it in the following way.
:~# ufw allow 5984/tcp
Next, open your web browser and go to http://Your-server:5984/_utils and now you can log in.
And you can check the databases.
So, that is it.
Conclusion
CouchDB is clearly oriented to the professional web sector. However, its learning curve is low with respect to its power. Despite this, CouchDB is easily installable as we have seen.
Please share this post with your friends.