Installation

Note

Please check the software requirements, before installing OC.

Windows (Instruction is deprecated. It will be renewed.)

Instructions:

  1. Install Node.js
  2. Install yarn
  3. Download the project from the bitbucket or clone it with the git tool on your pc.
  4. Open the front-end folder with IDE tool or in terminal/command line.
  5. Run the next command to install node-modules:
  1. Run the next command to run the project:
[email protected]> yarn start

After that, your browser should automatically open a new tab with url: http://localhost:3000/

  1. Install JDK and JRE.

  2. Unpack the Gradle into c:\Gradle

  3. Install MariaDB

  4. Unpack Neo4j Community version into c:\Neo4j

  5. Run the next command

    setx path “%path%;[path_to_jdk];[path_to_jre];[path_to_gradle];[path_to_neo4j];[path_to_mariadb] M”

Debian/Ubuntu (example for 18.04 LTS)

Prepare environment:

  1. Update Debian/Ubuntu system:
1
2
3
[email protected]> apt update
[email protected]> apt install unzip
[email protected]> apt-get install libpng-dev libcurl4-gnutls-dev libexpat1-dev gettext libz-dev libssl-dev*
  1. Install nodejs:
1
2
3
4
[email protected]> sudo apt install curl (if debian)
[email protected]> curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash -
[email protected]> apt-get install -y nodejs
[email protected]> nodejs -v // to check
  1. Install yarn:
1
2
3
4
[email protected]> curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
[email protected]> echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
[email protected]> apt-get update && apt-get install yarn
[email protected]> yarn -v // to check
  1. Install git:
1
2
[email protected]> apt-get install git
[email protected]> git --version // to check
  1. Install java:
1
2
3
[email protected]> apt install openjdk-8-jdk
[email protected]> apt install openjdk-8-jre (can be optional)
[email protected]> java -version // to check
  1. Install gradle:
1
2
3
4
5
[email protected]> apt-get install software-properties-common (if debian)
[email protected]> add-apt-repository ppa:cwchien/gradle
[email protected]> apt-get update
[email protected]> apt upgrade gradle
[email protected]> gradle -v // to check
  1. Install neo4j:
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
[email protected]> wget --no-check-certificate -O - https://debian.neo4j.org/neotechnology.gpg.key | sudo apt-key add -
[email protected]> echo 'deb http://debian.neo4j.org/repo stable/' > /etc/apt/sources.list.d/neo4j.list
[email protected]> apt update
[email protected]> apt install neo4j
[email protected]> /usr/bin/neo4j-admin set-initial-password secret // change password if you want
[email protected]> service neo4j status  // to check
[email protected]> sed -i '/#dbms.connectors.default_listen_address=0.0.0.0/c\dbms.connectors.default_listen_address=0.0.0.0' /etc/neo4j/neo4j.conf
[email protected]> sed -i '/#dbms.security.auth_enabled=false/c\dbms.security.auth_enabled=false' /etc/neo4j/neo4j.conf
[email protected]> service neo4j restart
[email protected]> systemctl enable neo4j
  1. Install MariaDB:
1
2
3
4
5
[email protected]> apt install mariadb-server mariadb-client
[email protected]> mysql_secure_installation // set password
[email protected]> mysql -u root -e "UPDATE mysql.user SET plugin = 'mysql_native_password' WHERE User = 'root';"
[email protected]> mysql -u root -e "FLUSH PRIVILEGES"
[email protected]> mysql --version // to check
  1. Install MY-NETDATA:
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
if debian
[email protected]> sudo apt-get install zlib1g-dev uuid-dev libmnl-dev pkg-config gcc make autoconf autoconf-archive autogen automake python python-yaml python-mysqldb nodejs lm-sensors python-psycopg2 netcat
[email protected]> git clone https://github.com/firehol/netdata.git --depth=1 /usr/lib/netdata
[email protected]> cd /usr/lib/netdata
[email protected]> sudo ./netdata-installer.sh

if ubuntu
[email protected]> apt-get install netdata -y
[email protected]> sed -i '/\tbind socket to IP = 127.0.0.1/c\\tbind socket to IP = 0.0.0.0' /etc/netdata/netdata.conf
[email protected]> wget https://bitbucket.org/becon_gmbh/opencelium/raw/cf5b43c102cca25d0a7abe778f1de0fe0c4e40c7/docs/netdata/oc-mode.html -O /usr/share/netdata/web/oc-mode.html
[email protected]> chown netdata:netdata /usr/share/netdata/web/oc-mode.html (if debian)
[email protected]> systemctl restart netdata
  1. Install Elasticsearch (optional)
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
 [email protected]> apt-get install apt-transport-https
 [email protected]> wget -qO - https://artifacts.elastic.co/GPG-KEY-elasticsearch | sudo apt-key add -
 [email protected]> add-apt-repository "deb https://artifacts.elastic.co/packages/7.x/apt stable main"
 [email protected]> apt-get update
 [email protected]> apt-get install elasticsearch
 [email protected]> sed -i '/\#cluster.name: my-application/c\cluster.name: opencelium' /etc/elasticsearch/elasticsearch.yml
 [email protected]> sed -i '/\#network.host: 192.168.0.1/c\network.host: 0.0.0.0' /etc/elasticsearch/elasticsearch.yml
 [email protected]> echo "cluster.initial_master_nodes: node-1" >> /etc/elasticsearch/elasticsearch.yml
 [email protected]> /bin/systemctl enable elasticsearch.service
 [email protected]> systemctl start elasticsearch.service

Note

If elasticsearch not running, check if “transport.host: localhost” is set in /etc/elasticsearch/elasticsearch.yml

  1. Install Kibana (optional)
1
2
3
4
5
 [email protected]> apt-get install kibana
 [email protected]> sed -i '/\#server.host: "localhost"/c\server.host: "0.0.0.0"' /etc/kibana/kibana.yml
 [email protected]> sed -i '/\#elasticsearch.hosts: ["http://localhost:9200"]/c\elasticsearch.hosts: ["http://localhost:9200"]' /etc/kibana/kibana.yml
 [email protected]> /bin/systemctl enable kibana.service
 [email protected]> service kibana start

Install Application:

  1. Get frontend repository
[email protected]> cd /opt
[email protected]> git clone -b <StableVersion> https://bitbucket.org/becon_gmbh/opencelium.git // Get stable versions here https://bitbucket.org/becon_gmbh/opencelium/downloads/?tab=tags
[email protected]> mv opencelium/* .
[email protected]> mv opencelium/.* .
[email protected]> rmdir opencelium
  1. Build frontend project
[email protected]> cd src/frontend
[email protected]> yarn
[email protected]> echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p // increasing the amount of inotify watchers
  1. Enable OC service
[email protected]> ln -s /opt/scripts/oc_service.sh /usr/bin/oc
  1. Start frontend
[email protected]> oc start_frontend
  1. Create application.yml file for backend
[email protected]> cd /opt/src/backend
[email protected]> cp src/main/resources/application_default.yml src/main/resources/application.yml
[email protected]> // make changes inside of application.yml. change neo4j and mysql database password
  1. Install database
[email protected]> cd /opt/src/backend/database
[email protected]> mysql -u root -p -e "source oc_data.sql"
  1. Build backend project
[email protected]> cd /opt/src/backend/
[email protected]> gradle build
  1. Start backend
[email protected]> oc start_backend
  1. Welcome to OC
Visit opencelium http://SERVERIP:8888

Note

If yarn not run use this command: echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p

SUSE Linux Enterprise Server (example for SLES 15 SP1)

Prepare environment:

  1. Install nodejs:
1
2
3
4
[email protected]> zypper addrepo http://download.opensuse.org/repositories/devel:/languages:/nodejs/SLE_15_SP1 node10
[email protected]> zypper refresh
[email protected]> zypper install nodejs10
[email protected]> node -v
  1. Install yarn:
1
2
[email protected]> sudo npm install yarn -g
[email protected]> yarn -v // to check
  1. Install git:
1
2
[email protected]> zypper install git
[email protected]> git --version // to check
  1. Install java:
1
2
3
[email protected]> zypper install java-1_8_0-openjdk
[email protected]> zypper install java-1_8_0-openjdk-devel
[email protected]> java -version // to check
  1. Install gradle:
1
2
3
4
5
6
[email protected]> cd /tmp
[email protected]> wget https://services.gradle.org/distributions/gradle-5.6.2-all.zip
[email protected]> mkdir /opt/gradle
[email protected]> unzip -d /opt/gradle gradle-5.6.2-all.zip
[email protected]> export PATH=$PATH:/opt/gradle/gradle-5.6.2/bin
[email protected]> gradle -v // to check
  1. Install neo4j:
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
[email protected]> zypper addrepo --refresh https://yum.neo4j.org/stable neo4j-repository
[email protected]> zypper refresh
[email protected]> zypper install neo4j-3.5.11
[email protected]> /usr/bin/neo4j-admin set-initial-password secret // change password if you want
[email protected]> neo4j start
[email protected]> neo4j status  // to check
[email protected]> sed -i '/#dbms.connectors.default_listen_address=0.0.0.0/c\dbms.connectors.default_listen_address=0.0.0.0' /etc/neo4j/neo4j.conf
[email protected]> sed -i '/#dbms.security.auth_enabled=false/c\dbms.security.auth_enabled=false' /etc/neo4j/neo4j.conf
[email protected]> neo4j restart
[email protected]> zypper install insserv
[email protected]> systemctl enable neo4j
  1. Install MariaDB:
1
2
3
4
[email protected]> zypper install mariadb mariadb-client
[email protected]> rcmysql start
[email protected]> mysql_secure_installation // set password
[email protected]> mysql --version // to check
  1. Install MY-NETDATA:
1
2
3
4
5
6
7
8
9
[email protected]> zypper addrepo https://download.opensuse.org/repositories/devel:libraries:c_c++/SLE_15_SP1/devel:libraries:c_c++.repo
[email protected]> zypper refresh
[email protected]> zypper install zlib-devel libuv-devel libuuid-devel pkg-config gcc make autoconf autoconf-archive autogen automake python python-yaml nodejs netcat
[email protected]> git clone https://github.com/firehol/netdata.git --depth=1 /usr/lib/netdata
[email protected]> cd /usr/lib/netdata
[email protected]> sudo ./netdata-installer.sh
[email protected]> wget https://bitbucket.org/becon_gmbh/opencelium/raw/cf5b43c102cca25d0a7abe778f1de0fe0c4e40c7/docs/netdata/oc-mode.html -O /usr/share/netdata/web/oc-mode.html
[email protected]> chown netdata:netdata /usr/share/netdata/web/oc-mode.html
[email protected]> service netdata status
  1. Install Elasticsearch (optional)
1
2
3
4
5
6
7
8
9
 [email protected]> rpm --import https://artifacts.elastic.co/GPG-KEY-elasticsearch
 [email protected]> echo -e "[elasticsearch-7.x]\nname=Elasticsearch repository for 7.x packages\nbaseurl=https://artifacts.elastic.co/packages/oss-7.x/yum\ngpgcheck=1\ngpgkey=https://artifacts.elastic.co/GPG-KEY-elasticsearch\nenabled=1\nautorefresh=1\ntype=rpm-md" >> /etc/zypp/repos.d/elasticsearch.repo
 [email protected]> zypper install elasticsearch-oss
 [email protected]> sed -i '/\#cluster.name: my-application/c\cluster.name: opencelium' /etc/elasticsearch/elasticsearch.yml
 [email protected]> sed -i '/\#network.host: 192.168.0.1/c\network.host: 0.0.0.0' /etc/elasticsearch/elasticsearch.yml
 [email protected]> echo "cluster.initial_master_nodes: node-1" >> /etc/elasticsearch/elasticsearch.yml
 [email protected]> chkconfig elasticsearch on
 [email protected]> systemctl daemon-reload
 [email protected]> systemctl restart elasticsearch.service
  1. Install Kibana (optional)
1
2
3
4
5
6
7
 [email protected]> echo -e "[kibana-7.x]\nname=Kibana repository for 7.x packages\nbaseurl=https://artifacts.elastic.co/packages/7.x/yum\ngpgcheck=1\ngpgkey=https://artifacts.elastic.co/\GPG-KEY-elasticsearch\nenabled=1\nautorefresh=1\ntype=rpm-md" >> /etc/zypp/repos.d/kibana.repo
 [email protected]> zypper install kibana
 [email protected]> sed -i '/\#server.host: "localhost"/c\server.host: "0.0.0.0"' /etc/kibana/kibana.yml
 [email protected]> sed -i '/\#elasticsearch.hosts: ["http://localhost:9200"]/c\elasticsearch.hosts: ["http://localhost:9200"]' /etc/kibana/kibana.yml
 [email protected]> chkconfig kibana on
 [email protected]> systemctl daemon-reload
 [email protected]> systemctl restart kibana.service

Install Application:

  1. Get frontend repository
[email protected]> cd /opt
[email protected]> git clone -b <StableVersion> https://bitbucket.org/becon_gmbh/opencelium.git // Get stable versions here https://bitbucket.org/becon_gmbh/opencelium/downloads/?tab=tags
[email protected]> mv opencelium/* .
[email protected]> mv opencelium/.* .
[email protected]> rmdir opencelium
  1. Run frontend with yarn
[email protected]> cd src/frontend
[email protected]> yarn
[email protected]> echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p // increasing the amount of inotify watchers
  1. Enable OC service
[email protected]> ln -s /opt/scripts/oc_service.sh /usr/bin/oc
  1. Start frontend
[email protected]> oc start_frontend
  1. Create application.yml file for backend
[email protected]> cd /opt/src/backend
[email protected]> cp src/main/resources/application_default.yml src/main/resources/application.yml
[email protected]> // make changes inside of application.yml. change neo4j and mysql database password
  1. Install database
[email protected]> cd /opt/src/backend/database
[email protected]> mysql -u root -p -e "source oc_data.sql"
  1. Build backend project
[email protected]> cd /opt/src/backend/
[email protected]> gradle build
  1. Start backend
[email protected]> oc start_backend
  1. Welcome to OC
Visit opencelium http://SERVERIP:8888

Red Hat Enterprise Linux

Prepare environment:

  1. Update Red Hat system:
1
[email protected]> yum update
  1. Install nodejs:
1
2
3
4
[email protected]> yum install -y gcc-c++ make
[email protected]> curl -sL https://rpm.nodesource.com/setup_12.x | sudo -E bash -
[email protected]> yum install nodejs
[email protected]> node -v // to check
  1. Install yarn:
1
2
3
[email protected]> curl --silent --location https://dl.yarnpkg.com/rpm/yarn.repo | sudo tee /etc/yum.repos.d/yarn.repo
[email protected]> yum install yarn
[email protected]> yarn -v // to check
  1. Install git:
1
2
[email protected]> yum install git
[email protected]> git --version // to check
  1. Install java:
1
2
3
[email protected]> yum install java-1.8.0-openjdk
[email protected]> yum install java-1.8.0-openjdk-devel
[email protected]> java -version // to check
  1. Install gradle:
1
2
3
4
5
6
[email protected]> cd /tmp
[email protected]> wget https://services.gradle.org/distributions/gradle-5.6.2-all.zip
[email protected]> mkdir /opt/gradle
[email protected]> unzip -d /opt/gradle gradle-5.6.2-all.zip
[email protected]> export PATH=$PATH:/opt/gradle/gradle-5.6.2/bin
[email protected]> gradle -v // to check
  1. Install neo4j:
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
[email protected]> rpm --import https://debian.neo4j.org/neotechnology.gpg.key
[email protected]> cat <<EOF>  /etc/yum.repos.d/neo4j.repo
                        [neo4j]
                        name=Neo4j RPM Repository
                        baseurl=https://yum.neo4j.org/stable
                        enabled=1
                        gpgcheck=1
                        EOF
[email protected]> yum install neo4j-3.5.11
[email protected]> /usr/bin/neo4j-admin set-initial-password secret // change password if you want
[email protected]> service neo4j status  // to check
[email protected]> sed -i '/#dbms.connectors.default_listen_address=0.0.0.0/c\dbms.connectors.default_listen_address=0.0.0.0' /etc/neo4j/neo4j.conf
[email protected]> sed -i '/#dbms.security.auth_enabled=false/c\dbms.security.auth_enabled=false' /etc/neo4j/neo4j.conf
[email protected]> service neo4j restart
[email protected]> systemctl enable neo4j
  1. Install MariaDB:
1
2
3
4
[email protected]> yum install mariadb-server
[email protected]>     service mariadb start
[email protected]> mysql_secure_installation // set password
[email protected]> mysql --version // to check
  1. Install MY-NETDATA:
1
2
3
4
5
6
7
8
9
if debian
[email protected]> yum install zlib-devel libuuid-devel libmnl-devel gcc make git autoconf autogen automake pkgconfig
[email protected]> git clone https://github.com/firehol/netdata.git --depth=1 /usr/lib/netdata
[email protected]> cd /usr/lib/netdata
[email protected]> sudo ./netdata-installer.sh
[email protected]> sed -i '/\tbind socket to IP = 127.0.0.1/c\\tbind socket to IP = 0.0.0.0' /etc/netdata/netdata.conf
[email protected]> wget https://bitbucket.org/becon_gmbh/opencelium/raw/cf5b43c102cca25d0a7abe778f1de0fe0c4e40c7/docs/netdata/oc-mode.html -O /usr/share/netdata/web/oc-mode.html
[email protected]> chown netdata:netdata /usr/share/netdata/web/oc-mode.html
[email protected]> systemctl restart netdata

Install Application:

  1. Get frontend repository
[email protected]> cd /opt
[email protected]> git clone -b <StableVersion> https://bitbucket.org/becon_gmbh/opencelium.git // Get stable versions here https://bitbucket.org/becon_gmbh/opencelium/downloads/?tab=tags
[email protected]> mv opencelium/* .
[email protected]> mv opencelium/.* .
[email protected]> rmdir opencelium
  1. Run frontend with yarn
[email protected]> cd src/frontend
[email protected]> yarn
[email protected]> echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p // increasing the amount of inotify watchers
  1. Enable OC service
[email protected]> cp -a /opt/scripts/oc_service.sh /usr/bin/oc
[email protected]> oc start_frontend
  1. Create application.yml file for backend
[email protected]> cd /opt/src/backend
[email protected]> cp src/main/resources/application_default.yml src/main/resources/application.yml
[email protected]> // make changes inside of application.yml. change neo4j and mysql database password
  1. Install database
[email protected]> cd /opt/src/backend/database
[email protected]> mysql -u root -p -e "source oc_data.sql"
  1. Build backend project
[email protected]> cd /opt/src/backend/
[email protected]> gradle build
  1. Start backend
[email protected]> oc start_backend
  1. Welcome to OC
Visit opencelium http://SERVERIP:8888

Note

Please make sure that firewall is disabled (service firewalld stop)!

Ansible

Note

Only available for Ubuntu system (>=16.04 LTS)!

Prepare environment:

  1. Install Ansible:

Note

Use default Ansible installation guide. You can find documentation here -> https://docs.ansible.com/ansible/latest/installation_guide/intro_installation.html

  1. Get oc playbook:
1
2
3
4
5
[email protected]> cd /etc/ansible
[email protected]> git clone https://bitbucket.org/becon_gmbh/opencelium.setup.ansible.git
[email protected]> mv opencelium.setup.ansible/* ./
[email protected]> mv opencelium.setup.ansible/.* ./
[email protected]> rmdir opencelium.setup.ansible
  1. Add localhost in ansible
[email protected]> printf "[local]\nlocalhost ansible_connection=local" >> hosts
  1. Run playbook
[email protected]> ansible-playbook --connection=local -e 'host_key_checking=False' playbooks/install_oc.yml