Install RethinkDB on Ubuntu
RethinkDB – A NO-SQL database
RethinkDB is an open-source no-SQL database for real-time web applications. Using JSON, Web applications can be loaded into and read from the DB in real-time data. In contrast to the classic SQL database, no table is created, but strings, in which whole objects can be stored. These can theoretically be interlaced infinitely. The stored data can then be filtered and searched for every object. This makes databases more effective and easier to map the data structure of the application. However, these are not easily usable, the corresponding drivers have to be installed first in order to have access to the database with the respective programming language.
How RethinkDB can be installed on an Ubuntu 16.04 LTS server is shown in this article. This is a walk-through in the course of the installation. If you want to try RethinkDB only once and do not use it productively, it is recommended to create a server at gridscale, which takes only a few seconds. How to create a server at gridscale is explained in “How to gridscale”.
If a server is created, it takes only 3 minutes from here to the end of the tutorial.
Preparing Ubuntu Server
RethinkDB is not yet included in Ubuntu’s standard repository, so the vendor’s repository must be manually added. The following command is used for this:
source /etc/lsb-release && echo "deb http://download.rethinkdb.com/apt $DISTRIB_CODENAME main" | sudo tee /etc/apt/sources.list.d/rethinkdb.list
Then a key is needed, which verifies the download from the repository. Use the following command to download and install the key:
wget -qO- http://download.rethinkdb.com/apt/pubkey.gpg | sudo apt-key add -
The server must then be updated. The following command can be used for this:
apt -y update && apt -y upgrade && apt -y dist-upgrade
Now the server is ready to install RethinkDB.
After the repository has been added by RethinkDB, it can be installed with APT. Use the following command:
apt -y install rethinkdb
Then RethinkDB is installed on the server.
Selecting the Webinterface
RethinkDB provides a convenient web interface to display the utilization of DB (and many other useful features!).
To start the RethinkDB and make it available via the public IP address, the following command will help:
rethinkdb --bind all &
In order to bind RethinkDB only to internal IPs, however, this command must be used:
Afterwards, the input must be confirmed again with Enter.
Now open a browser and change to the IP of the server and the port 8080.
To stop the service, the following command is intended:
service rethinkdb stop
With these few steps, a RethinkDB can be installed on a server in a short time and used directly in your application. The great advantage of RethinkDB lies clearly in the real-time optimization. Both the server structure and the available drivers are designed for this. For developers, NoSQL databases have the great advantage that large objects can be stored directly in the database and the database can map the state of the application without abstraction. Therefore, it is worth looking at NoSQL databases like RethinkDB, MongoDB or Redis for many applications.
More information about the NoSQL databases and their installations can be found under the following articles:
Install MongoDB on Ubuntu
Install Redis on Ubuntu
RethinkDB – A NO-SQL database RethinkDB is an open-source no-SQL database for real-time web applications. Using JSON, Web applications can be loaded into and read from the DB in real-time data. In contrast to the classic SQL database, no table is created, but strings, in which whole objects can be stored. These can theoretically be interlaced infinitely. The […]
Vielen Dank für dein Feedback!
Wir melden uns bei dir, sobald der Artikel zu deinem Wunschthema fertig ist.