CentOSLinuxTutorials

How To Install OrientDB on CentOS 7

Install OrientDB on CentOS 7

In this tutorial, we will show you how to install OrientDB on your CentOS 7. For those of you who didn’t know, OrientDB has a multi-model NoSQL database that supports document databases with a graph it is a java based application and can be run on any operating system which supports multi-master replication and easy horizontal scaling.

This article assumes you have at least basic knowledge of Linux, know how to use the shell, and most importantly, you host your site on your own VPS. The installation is quite simple and assumes you are running in the root account, if not you may need to add ‘sudo‘ to the commands to get root privileges. I will show you the step-by-step installation of OrientDB’s open-source NoSQL database management system on a CentOS 7 server.

Prerequisites

  • A server running one of the following operating systems: CentOS 7.
  • It’s recommended that you use a fresh OS install to prevent any potential issues.
  • SSH access to the server (or just open Terminal if you’re on a desktop).
  • An active internet connection.
  • A non-root sudo user or access to the root user. We recommend acting as a non-root sudo user, however, as you can harm your system if you’re not careful when acting as the root.

Install OrientDB on CentOS 7

Step 1. First, let’s start by ensuring your system is up-to-date.

yum clean all
yum -y update

Step 2. Installing OrientDB.

First of all, create a new user to run OrientDB:

adduser orientdb -d /opt/orientdb

Now you can download the OrientDB binary archive by running the following command:

cd /opt/orientdb/
wget https://orientdb.com/download.php?file=orientdb-community-importers-2.2.29.tar.gz -O /opt/orientdb/orientdb.tar.gz

Once the package is downloaded we will untar and move the extracted folder to the /opt/orientdb:

tar -xf orientdb.tar.gz
mv orientdb-community*/* .

Make the OrientDB user the owner of the extracted files:

chown -R orientdb:orientdb /opt/orientdb

Step 3. Starting the OrientDB Server.

OrientDB provides an installer script for you to start the server. Switch to the OrientDB user:

su - orientdb
sudo bin/server.sh

OrientDB should now prompt for the root password with a message like the one below:

+---------------------------------------------------------------+
|                WARNING: FIRST RUN CONFIGURATION               |
+---------------------------------------------------------------+
| This is the first time the server is running. Please type a   |
| password of your choice for the 'root' user or leave it blank |
| to auto-generate it.                                          |
|                                                               |
| To avoid this message set the environment variable or JVM     |
| setting ORIENTDB_ROOT_PASSWORD to the root password to use.   |
+---------------------------------------------------------------+

Step 4. Configure OrientDB Daemon.

Create a new systemd service to easily manage OrientDB start and stop:

nano /etc/systemd/system/orientdb.service

Paste the following content:

[Unit]
Description=OrientDB service
After=network.target

[Service]
Type=simple
ExecStart=/opt/orientdb/bin/server.sh
User=orientdb
Group=orientdb
Restart=always
RestartSec=9
StandardOutput=syslog
StandardError=syslog
SyslogIdentifier=orientdb

[Install]
WantedBy=multi-user.target

Reload systemd daemon service:

systemctl daemon-reload

Start OrientDB and enable it for starting at boot time:

systemctl start orientdb
systemctl enable orientdb

Congratulations! You have successfully installed OrientDB. Thanks for using this tutorial for installing OrientDB open-source NoSQL database management on your CentOS 7 system. For additional help or useful information, we recommend you check the official OrientDB website.

VPS Manage Service Offer
If you don’t have time to do all of this stuff, or if this is not your area of expertise, we offer a service to do “VPS Manage Service Offer”, starting from $10 (Paypal payment). Please contact us to get the best deal!

Save

r00t

r00t is an experienced Linux enthusiast and technical writer with a passion for open-source software. With years of hands-on experience in various Linux distributions, r00t has developed a deep understanding of the Linux ecosystem and its powerful tools. He holds certifications in SCE and has contributed to several open-source projects. r00t is dedicated to sharing her knowledge and expertise through well-researched and informative articles, helping others navigate the world of Linux with confidence.
Back to top button