Installing CouchDB 2.0 on Ubuntu 20.04
Traducciones al EspañolEstamos traduciendo nuestros guías y tutoriales al Español. Es posible que usted esté viendo una traducción generada automáticamente. Estamos trabajando con traductores profesionales para verificar las traducciones de nuestro sitio web. Este proyecto es un trabajo en curso.
CouchDB is a non-relational, or “NoSQL” database designed with scalability and a more trouble-free experience in mind. CouchDB is programmed in Erlang, which boasts a highly scalable concurrency model and fault tolerance. CouchDB capitalizes on both of these features to ensure production databases run with fewer interruptions, regardless of changes in request volumes and inevitable performance potholes.
CouchDB uses HTTP APIs and JSON documents which are intended to be more intuitive and to integrate more simply into web and mobile applications. Its use of JSON documents makes it highly flexible and able to accommodate a wide variety of needs.
This guide shows you how to install CouchDB on Ubuntu 20.04. At the end of this guide, there is a link to a subsequent guide for getting started using CouchDB and understanding its concepts.
Before You Begin
If you have not already done so, create a Linode account and Compute Instance. See our Getting Started with Linode and Creating a Compute Instance guides.
Follow our Setting Up and Securing a Compute Instance guide to update your system. You may also wish to set the timezone, configure your hostname, create a limited user account, and harden SSH access.
sudo
. If you are not familiar with the sudo
command, see the
Linux Users and Groups guide.Set Up the Apache CouchDB Repository
Install the prerequisites for using the Apache CouchDB repository using the following commands:
sudo apt update && sudo apt install -y curl apt-transport-https gnupg curl https://couchdb.apache.org/repo/keys.asc | gpg --dearmor | sudo tee /usr/share/keyrings/couchdb-archive-keyring.gpg >/dev/null 2>&1 source /etc/os-release
Add the CouchDB repository to the
apt
repository list.echo "deb [signed-by=/usr/share/keyrings/couchdb-archive-keyring.gpg] https://apache.jfrog.io/artifactory/couchdb-deb/ ${VERSION_CODENAME} main" | sudo tee /etc/apt/sources.list.d/couchdb.list >/dev/null
Install the CouchDB repository key.
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 8756C4F765C9AC3CB6B85D62379CE192D401AB61
Install CouchDB
The steps below are for installing a standalone CouchDB server. If you intend to use CouchDB in a cluster, choose clustered instead of standalone and enter 0.0.0.0
as the interface bind-address in the steps that follow.
See CouchDB’s Cluster Set Up guide for the additional steps needed to set up a CouchDB cluster once you have completed the installation.
Update the package manager.
sudo apt update
Install CouchDB.
sudo apt install -y couchdb
Choose standalone when prompted for a configuration type.
Enter the default value —
127.0.0.1
— for the interface bind address.Since CouchDB 3.0.0, CouchDB does not run without an administrator user being configured. When prompted, create an administrator user by entering a password. Re-enter the password on the subsequent screen.
You can verify that CouchDB is installed by running the following command.
Replace
admin
andpassword
with the username and password, respectively, for a valid CouchDB user.To use the administrator user you created during the installation process, enter the username, which is
admin
by default, and the password you set up.curl admin:password@127.0.0.1:5984
Get Started with CouchDB
You have now successfully installed CouchDB! To get started, head over to the guide for Using CouchDB on Ubuntu 20.04.
More Information
You may wish to consult the following resources for additional information on this topic. While these are provided in the hope that they will be useful, please note that we cannot vouch for the accuracy or timeliness of externally hosted materials.
This page was originally published on