On premise

Ubuntu 18.04 64 bit – Single machine (on premise)

Hardware requirements

To install sibylla on your system you need at least:

  • 4 core CPU
  • 16 GB RAM
  • 256 GB of disk space

Prerequisites

To install sibylla on your system you need to install:

  • JRE 11 (commercial or open)
  • node 11.2.0
  • nginx (It is the entry point for the Sibylla platform: console, cores, gateways, …)
  • A user sibylla (group sibylla)
  • Utilities: vi, wget, …

Download the sibylla installation package (community edition)

Login into the machine as user: sibylla.

Get the product from here and place in the parent directory you want sibylla to be installed:

cd <parent directory of the sibylla being installed> (Suggested: the home directory of the sibylla user)
wget https://github.com/greenvulcano/sibylla-documentation/releases/download/1.0.0-RELEASE/sibylla-platform-1.0.0-RELEASE.tar.gz

Prepare the directory structure

From the parent directory where you want to install sibylla, untar the sibylla package. it will create a directory sibylla with all the subfolders of the product:

tar xzvf sibylla-platform-1.0.0-RELEASE.tar.gz

Set the environment

Modify the sibylla/scripts/set-environment.source-me to meet your environment:

vi sibylla/scripts/set-environment.source-me

Verify these ENV variables and set them to the correct path. If for you is ok this setting, skip this step

export PRJ_HOME="/home/`whoami`/<folder in which the sibylla tar was extracted>
export SIBYLLA_HOME=$PRJ_HOME

Load the sibylla environment at login:

vi .bashrc

(or equivalent)

Add this line at the end of the script

source <path to the sibylla directory>/scripts/set-environment.source-me

Test the new settings: logout and login. You should see the Sibylla IoT platform splash screen.

Configure the application config file

Configure sibylla.conf

Modify the content of the file to reflect your environment (comment what you don’t want to run on the current machine):


##############################################
# Instance name          #   port    hosts
##############################################
db                                   localhost
mongodb                              localhost
zk                                   localhost
kafka                                localhost
jms-main                             localhost
metabase                             localhost
core                     1   18180   localhost
console                              localhost
n-1-gateway-http         1   21100   localhost
n-1-gateway-mqtt         1           localhost
n-1-datapump-mongodb     1           localhost
n-1-datapump-websocket   1           localhost

Download these third parties software (portable option)

You can skip any of these steps if you already have these third party components installed somewhere else, as for example in the case MySql is installed externally on a different machine or as a service on the same machine. In this case make sure you have full control of these components and save the connection parameters somewhere, because you will need the connection information.

The procedure that follows consider the Portable_application approach:

Download the packages into the downloads directory:

cd $SIBYLLA_HOME/downloads
wget https://dev.mysql.com/get/Downloads/MySQL-8.0/mysql-8.0.15-linux-glibc2.12-x86_64.tar.xz (10/2019 - 8.0.18 available)
wget https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-ubuntu1804-4.0.6.tgz (10/2019 - 4.2.0 available)
wget http://it.apache.contactlab.it/kafka/2.1.1/kafka_2.12-2.1.1.tgz (10/2019 - 2.3.0 available)
wget http://it.apache.contactlab.it/activemq/5.15.9/apache-activemq-5.15.9-bin.tar.gz (10/2019 - 5.15.0 available)
wget https://www.emqx.io/downloads/broker/v3.1-beta.2/emqx-ubuntu18.04-v3.1-beta.2.zip (10/2019 - 4.0 beta 1)
wget http://downloads.metabase.com/v0.31.2/metabase.jar (10/2019 - 0.33.4)
wget ELK TODO

 

Package Version Download at
MySQL 8.0 – Linux generic – 64 bits mysql-8.0.15-linux-glibc2.12-x86_64.tar.xz
Mongo 4.0.6 – Ubuntu 18.04 64 bits – tgz mongodb-linux-x86_64-ubuntu1804-4.0.6.tgz
Kafka 2.1.1 – Scala 2.12 – kafka_2.12-2.1.1.tgz (asc, sha512) kafka_2.12-2.1.1.tgz
ActiveMQ Unix/Linux/Cygwin Distribution apache-activemq-5.15.9-bin.tar.gz
EMQTT Linux – 3.1* – Ubuntu 18.04 – Zip emqx-ubuntu18.04-v3.1-beta.2.zip
Metabase Custom install – v0.31.2 metabase.jar

Install third party software (portable option)

This part of the procedure will prepare and test all 3rd party software.

MySQL

Untar mysql into the sibylla/3rd-party/db-domain/bin directory:

cd $SIBYLLA_HOME/3rd-party/db-domain/bin
tar -xJvf $SIBYLLA_HOME/downloads/mysql-8.0.15-linux-glibc2.12-x86_64.tar.xz
ln -s mysql-8.0.15-linux-glibc2.12-x86_64 mysql

MYSQL configuration and DB initialization (In case of doubts follow the official procedure defined at MySQL docs)

sibylla setup db
cd $SIBYLLA_HOME/3rd-party/db-domain
rm data/README.md

First time the DB has to be initialized, the data directory has to exist and MUST be empty

./bin/mysql/bin/mysqld --defaults-file=./config/sibylla.cnf --initialize

Only 4 Docker (libs not previously installed)

apt-get install libaio1 libaio-dev
apt-get install numactl
./bin/mysql/bin/mysql_ssl_rsa_setup --defaults-file=./config/sibylla.cnf
./bin/mysql/bin/mysqld --defaults-file=./config/sibylla.cnf &

Change password:
Note: A root auto generated password has been create by the “initialize” command

grep password ./logs/mysql.log
 	
Example: 2019-03-08T22:36:20.410102Z 5 [Note] [MY-010454] [Server] A temporary password is generated for root@localhost: #=heSyL3dfTF
bin/mysql/bin/mysql -u root -p

ALTER USER 'root'@'localhost' IDENTIFIED BY 'root';
CREATE USER 'sibylla' IDENTIFIED BY 'sibylla';
CREATE SCHEMA sibylla;
GRANT ALL PRIVILEGES ON sibylla.* TO 'sibylla'@'%';
use sibylla;
show tables;
exit

MongoDB
Untar the product:

cd $SIBYLLA_HOME/3rd-party/mongodb-domain/bin
tar xzvf $SIBYLLA_HOME/downloads/mongodb-linux-x86_64-ubuntu1804-4.0.6.tgz

Only 4 Docker (packages not previously installed)

apt-get install curl
apt-get install -y tzdata
ln -s mongodb-linux-x86_64-ubuntu1804-4.0.6 mongodb

MongoDB configuration:

sibylla setup mongodb

Kafka
Untar the product:

cd $SIBYLLA_HOME/3rd-party/kafka-domain
tar xzvf $SIBYLLA_HOME/downloads/kafka_2.12-2.1.1.tgz
ln -s kafka_2.12-2.1.1 kafka

Kafka and Zookeper configuration:

sibylla setup kafka
sibylla setup zk

ActiveMQ
Prepare the directory structure:

cd $SIBYLLA_HOME/3rd-party/jms-domain
tar xvzf $SIBYLLA_HOME/downloads/apache-activemq-5.15.9-bin.tar.gz
ln -s apache-activemq-5.15.9 activemq

ActiveMQ configuration:

sibylla setup jms-main

EMQX
Untar the product:

cd $SIBYLLA_HOME/3rd-party/mqtt-domain
unzip $SIBYLLA_HOME/downloads/emqx-ubuntu18.04-v3.1-beta.2.zip

Only 4 Docker (packages not previously installed)

apt-get install unzip

Version the installation to simplify future upgrade and tranfer of data:

mv emqx emqx-v3.1-beta.2
ln -s emqx-v3.1-beta.2 emqx

EMQX configuration: The configuration file is under ./emqx/etc. The basic installation does not require any specific configuration

Metabase
Untar the product:

cd $SIBYLLA_HOME/3rd-party/analytics-domain/metabase/bin
cp $SIBYLLA_HOME/downloads/metabase.jar .

Configure Metabase: The basic installation does not require any specific configuration.

Install the Sibylla platform components

Download the platform

sibylla download-app

Configure the platform

sibylla setup core
sibylla setup console

Test the start and stop of the application

sibylla start-3rd-parties

(or iot start)

sibylla stop-3rd-parties

(or iot stop)

If 3rd-party software is installed separately, comment the components on the related lines of the sibylla.com configuration file

sibylla start-app
sibylla status

Note: after the first start of the platform all the network components (datapumps, gateways) are not running; this is because the network configuration still must be done, as explained in the next section

sibylla stop-app
sibylla status
sibylla start console

Configure the Network
Open the Sibylla console, and go to the Networks page.
In the box reserved to the network you are to configure, click on the Copy to clipboard icon.
Past the copied network API Key every network component

cd $SIBYLLA_HOME
vi sibylla-network-1/sibylla-datapump-mongodb/config/application.properties

Past the copied value to the sibylla.platform.token property

vi sibylla-network-1/sibylla-datapump-websocket/config/application.properties

vi sibylla-network-1/sibylla-gateway-httpconfig/application.properties

vi sibylla-network-1/sibylla-gateway-mqtt/config/application.properties

Next reading: Getting started guide