OrientDB Installation - OrientDB

What is OrientDB Installation?

OrientDB installation file is available in two editions −

  • Community Edition − OrientDB community edition is released by Apache under 0.2 license as an open source
  • Enterprise Edition − OrientDB enterprise edition is released as a proprietary software, which is built on community edition. It serves as an extension of the community edition.
This section describes the installation process of OrientDB community edition for the reason that it is open source.

Prerequisites

Both community and Enterprise editions can run on any Operating system that implements the Java Virtual Machine (JVM). OrientDB requires Java with 1.7 or later version.
Use the subsequent steps to download and install OrientDB into your system.

Step 1 − Download OrientDB Binary Setup File

OrientDB comes with built-in setup file to install the database on your system. It provides different pre-compiled binary packages (tarred or zipped packages) for different operating systems. You can download OrientDB files from Download OrientDB link.
The subsequent screenshot shows the download page of OrientDB. You can download the zipped or tarred file by clicking the suitable operating system icon.
OrientDB insta 1
On downloading, you will get the binary package in your Downloads folder.

Step 2 − Extract and Install OrientDB

Subsequent is the method to extract and install OrientDB for different operating systems.

In Linux

After download you will get orientdb-community-2.1.9.tar.gz file in your Downloads folder. You can use the following command to extract the tarred file.
You can use the following command to move all the OrientDB library files from orientdbcommunity-2.1.9 to /opt/orientdb/ directory. Here we are using super user command (sudo) consequently you have to give super user password to execute the following command.
You can use the subsequent commands to register the orientdb command and the Orient server.

In Windows

  • After download you will get orientdb-community-2.1.9.zip file in your Downloads folder. Extract the zip file using the zip extractor.
  • Move the extracted folder into the C:\ directory.
  • Create two environmental variables ORIENTDB_HOME and PATH variables with following given values.

Step 3 − Configuring OrientDB Server as a Service

By subsequent the above steps you can use the Desktop version of OrientDB. You can start OrientDB database server as a service by using the following steps. The procedure is different, depending on your operating system.

In Linux

OrientDB provides a script file named orientdb.sh to run the database as a daemon. You can discover it in the bin/directory of your OrientDB installation directory that is $ORIENTDB_HOME/bin/orientdb.sh.
Ahead of running the script file, you have to edit orientdb.sh file for defining two variables. One is ORIENTDB_DIR which defines the path to the installation directory (/opt/orientdb) and the second is ORIENTDB_USER which defines the username you want run OrientDB for as follows.
Use the following command to copy orientdb.sh file into /etc/init.d/ directory for initializing and running the script. Here we are using super user command (sudo) therefore you have to provide super user password to execute the following command.
Use the subsequent command to copy the console.sh file from OrientDB installation directory that is $ORIENTDB_HOME/bin to the system bin directory that is /usr/bin for accessing the Orient DB’s console.
Use the subsequent command to start the ORIENTDB database server as service. Here you have to offer the respective user’s password which you mention in the orientdb.sh file to start the server.
Use the subsequent command to know on which PID the OrientDB server daemon is running.
Use the following command to stop the OrientDB server daemon. Here you have to provide the respective user’s password, which you mention in the orientdb.sh file to stop the server.

In Windows

OrientDB is a server application therefore it has to perform numerous tasks before starting shutting down the Java virtual machine process. If you want to shutdown OrientDB server manually then you have to execute shutdown.bat file. But the server instances do not stop correctly, when the system shuts down suddenly without executing the above script. The programs which are guarded by the operating system with a set of specified signals are called services in Windows.
We have to use Apache Common Daemon which allow Windows users to wrap Java applications as Windows service. Following is the procedure to download and register Apache common daemon.
  • Click the following link for Apache Common Daemons for windows.
  • Click on common-daemon-1.0.15-bin-windows to download.
  • Unzip the common-daemon-1.0.15-bin-windows directory. After extracting you will find prunsrv.exe and prunmgr.exe files inside the directory. In those −
    • prunsrv.exe file is a service application for running applications as services.
    • prunmgr.exe file is an application used for monitoring and configuring windows services.
  • Go to OrientDB installation folder → create a new directory and name it service.
  • Copy the prunsrv.exe and prunmgr .exe paste it into to the service directory.
  • In order to configure OrientDB as Windows service, you have to carry out a short script that uses the prusrv.exe as a Windows service.
  • Before defining the Windows Services, you have to rename prunsrv and prunmgr according to the name of the service. For e.g. OrientDBGraph and OrientDBGraphw respectively. Here OrientDBGraph is the name of the service.
  • Copy the following script into the file named installService.bat and place it into %ORIENTDB_HOME%\service\ directory.
The script requires two parameters −
  • The location of jvm.dll, for e.g. C:\ProgramFiles\java\jdk1.8.0_66\jre\bin\server\jvm.dll
  • The location of OrientDB installation for e.g. C:\orientdb-community-2.1.9
  • The service is installed when you execute the OrientDBGraph.exe file (Original prunsrv) and double-click on it.
  • Use the following command to install services into Windows.
Open the Task Manager services, you will find the following screenshot with the registered service name is in it.
Orient DB 2

Step 4 − Verifying OrientDB Installation

This step verifies the OrientDB database server installation using the following steps.
  • Run the server.
  • Run the console.
  • Run the studio.
This is unique according to the operating system.

In Linux

Follow the given procedure for verifying OrientDB installation in Linux.
Running the server − You can use the following command to start the server.
Or you can use the following command to start the OrientDB server as UNIX daemon.
If it is installed successfully, you will receive the following output.
.
.` `
, `:.
`,` ,:`
.,. :,,
.,, ,,,
. .,.::::: ```` ::::::::: :::::::::
,` .::,,,,::.,,,,,,`;; .: :::::::::: ::: :::
`,. ::,,,,,,,:.,,.` ` .: ::: ::: ::: :::
,,:,:,,,,,,,,::. ` ` `` .: ::: ::: ::: :::
,,:.,,,,,,,,,: `::, ,, ::,::` : :,::` :::: ::: ::: ::: :::
,:,,,,,,,,,,::,: ,, :. : :: : .: ::: ::: :::::::
:,,,,,,,,,,:,:: ,, : : : : .: ::: ::: :::::::::
` :,,,,,,,,,,:,::, ,, .:::::::: : : .: ::: ::: ::: :::
`,...,,:,,,,,,,,,: .:,. ,, ,, : : .: ::: ::: ::: :::
.,,,,::,,,,,,,: `: , ,, : ` : : .: ::: ::: ::: :::
...,::,,,,::.. `: .,, :, : : : .: ::::::::::: ::: :::
,::::,,,. `: ,, ::::: : : .: ::::::::: ::::::::::
,,:` `,,.
,,, .,`
,,. `, GRAPH DATABASE
`` `.
`` orientdb.com
`
2016-01-20 19:17:21:547 INFO OrientDB auto-config DISKCACHE = 1,
649MB (heap = 494MB os = 4, 192MB disk = 199, 595MB) [orientechnologies]
2016-01-20 19:17:21:816 INFO Loading configuration from:
/opt/orientdb/config/orientdb-server-config.xml... [OServerConfigurationLoaderXml]
2016-01-20 19:17:22:213 INFO OrientDB Server v2.1.9-SNAPSHOT
(build 2.1.x@r; 2016-01-07 10:51:24+0000) is starting up... [OServer]
2016-01-20 19:17:22:220 INFO Databases directory: /opt/orientdb/databases [OServer]
2016-01-20 19:17:22:361 INFO Port 0.0.0.0:2424 busy,
trying the next available... [OServerNetworkListener]
2016-01-20 19:17:22:362 INFO Listening binary connections on 0.0.0.0:2425
(protocol v.32, socket = default) [OServerNetworkListener]
...
2016-01-20 19:17:22:614 INFO Installing Script interpreter. WARN:
authenticated clients can execute any kind of code into the server
by using the following allowed languages:
[sql] [OServerSideScriptInterpreter]
2016-01-20 19:17:22:615 INFO OrientDB Server v2.1.9-SNAPSHOT
(build 2.1.x@r; 2016-01-07 10:51:24+0000) is active. [OServer]
Running the console − You can use the following command to run the OrientDB under console.
If it is installed successfully, you will receive the following output.
Running the Studio − After starting the server you can use the following URL (http://localhost:2480/) on your browser. You will get the following screenshot.
orient db 3

In Windows

Follow the given procedure for verifying OrientDB installation in Windows.
Running the server − You can use the subsequent command to start the server.
If it is installed successfully, you will receive the following output.
.
.` `
, `:.
`,` ,:`
.,. :,,
.,, ,,,
. .,.::::: ```` ::::::::: :::::::::
,` .::,,,,::.,,,,,,`;; .: :::::::::: ::: :::
`,. ::,,,,,,,:.,,.` ` .: ::: ::: ::: :::
,,:,:,,,,,,,,::. ` ` `` .: ::: ::: ::: :::
,,:.,,,,,,,,,: `::, ,, ::,::` : :,::` :::: ::: ::: ::: :::
,:,,,,,,,,,,::,: ,, :. : :: : .: ::: ::: :::::::
:,,,,,,,,,,:,:: ,, : : : : .: ::: ::: :::::::::
` :,,,,,,,,,,:,::, ,, .:::::::: : : .: ::: ::: ::: :::
`,...,,:,,,,,,,,,: .:,. ,, ,, : : .: ::: ::: ::: :::
.,,,,::,,,,,,,: `: , ,, : ` : : .: ::: ::: ::: :::
...,::,,,,::.. `: .,, :, : : : .: ::::::::::: ::: :::
,::::,,,. `: ,, ::::: : : .: ::::::::: ::::::::::
,,:` `,,.
,,, .,`
,,. `, GRAPH DATABASE
`` `.
`` orientdb.com
`
2016-01-20 19:17:21:547 INFO OrientDB auto-config DISKCACHE = 1,649MB
(heap = 494MB os = 4, 192MB disk = 199, 595MB) [orientechnologies]
2016-01-20 19:17:21:816 INFO Loading configuration from:
/opt/orientdb/config/orientdb-server-config.xml...
[OServerConfigurationLoaderXml]
...
2016-01-20 19:17:22:615 INFO OrientDB Server v2.1.9-SNAPSHOT
(build 2.1.x@r; 2016-01-07 10:51:24+0000) is active. [OServer]
Running the console − You can use the subsequent command to run OrientDB under console.
If it is installed effectively, you will receive the following output.
Running the Studio − After starting the server you can use the following URL (http://localhost:2480/) on your browser. You will get the following screenshot.
orient db 4

All rights reserved © 2018 Wisdom IT Services India Pvt. Ltd DMCA.com Protection Status

OrientDB Topics