Asimily Installation Guide - ni3galave/test-jekins GitHub Wiki
For Asimily installation will be considering three hosts in use.
- Target machine 1 will be edge
- Target machine 2 will be the onPrem
- Target machine 3 will be the Host machine.
let's consider : Target1, Target2, Target3
Prerequisite:
User need to clone below links on Host machine in a directory.
git clone https://github.com/AsimilyInc/networkAnalytics.git
git clone https://github.com/AsimilyInc/asimily-portal.git
git clone https://github.com/AsimilyInc/db-schema.git
git clone https://github.com/AsimilyInc/db-dumps-lfs.git
New installation
1. In this step we will create installation package (tar)
* Target3:
cd <path_to_network_analytics_dir>
bash packageFinal.sh -p -a -r 1.0.0 // Generate package by running following command
options : -p production,-d dev, -a all packages(onprem and edge), -r release version, -edd exclude database dumps
2. Following commands will create new installation directories as well as it will clean existing ones, if any
- Target1 and Target2 machine:
cd /home/<taget_machine_dir>/ (eg: /home/chedly/)
rm -rf /home/<taget_machine_dir>/tmp_installation/
mkdir /home/<taget_machine_dir>/tmp_installation/
- Target1:
mkdir -p /home/<taget_machine_dir>/tmp_installation/edge
- Target2:
mkdir -p /home/<taget_machine_dir>/tmp_installation/onPrem
3. Need to move and extract created packages in installation dir
- Target3:
cd /home/<taget_machine_dir>/<path_to_clone_dir>/networkAnalytics/target
scp asimily-edge.tar.gz /home/<Target1_machine>/tmp_installation/
scp asimily-onprem.tar.gz /home/<Target2_machine>/tmp_installation/
- Target1:
cd /home/<Target1_machine>/tmp_installation
tar zxvf asimily-edge.tar.gz -C edge/
- Target2:
cd /home/<Target2_machine>/tmp_installation
tar zxvf asimily-onprem.tar.gz -C onPrem/
4. For OnPrem installation follow below steps
- Target2: Modify asimily_install.properties file and make changes accordingly and then run following command to setup asimily.
rm -rf /opt/asimily // remove asimily folder if any
cd /home/<Target2_machine>/tmp_installation/onPrem
bash asimily_setup.sh onPrem
5. Verify the installed software version
- Target2 machine : Goto
/opt/asimily/onPrem
and check that the file ASIMILY_RELEASE_VER has proper version. Also the jar should have the same version as above
6. For Database Setup please follow below steps
- Target2:
cd /opt/asimily/onPrem/db-schema/scripts
bash asimily_db_setup.sh
Make sure you get success message and the DB is created
7. Start the on-prem modules
- Target2:
cd /opt/asimily/onPrem
bash runOnPremServer.sh
Check onPrem process is running or not with latest version.
Upgrade installation
- Clean existing/create installation directories
- Target1 and Target2 machine:
cd /home/<taget_machine_dir>/
rm -rf /home/<taget_machine_dir>/tmp_installation/
mkdir /home/<taget_machine_dir>/tmp_installation/
- Target1:
mkdir -p /home/<taget_machine_dir>/tmp_installation/edge
- Target2:
mkdir -p /home/<taget_machine_dir>/tmp_installation/onPrem
- Create installation package (tar):
- Target3:
cd <path_to_cloned_directories>/networkAnalytics/
bash packageFinal.sh -p -a -r 2.0.0 -edd
options: -p production, -a both package (onprem & edge), -r version, -edd exclude database dump 3. Move and extract created package to installation dir:
- Target3:
cd /home/<taget_machine_dir>/<cloned_directories>/networkAnalytics/target
scp asimily-edge.tar.gz /home/<Target1_machine>/tmp_installation/
scp asimily-onprem.tar.gz /home/<Target2_machine>/tmp_installation/
- Target1:
cd /home/<Target1_machine>/tmp_installation
tar zxvf asimily-edge.tar.gz -C edge/
- Target2:
cd /home/<Target2_machine>/tmp_installation
tar zxvf asimily-onprem.tar.gz -C onPrem/
- OnPrem installation:
- Target2 : Modify asimily_install.properties file and make changes accordingly and then run following command to setup asimily.
cd /opt/asimily/onPrem && ./cleanupAllProcesses.sh //TO make sure all the old version processes are stopped
mv /opt/asimily/onPrem /opt/asimily/onPrem_old_version
cd /home/<taget_machine_dir>/tmp_installation/onPrem
bash asimily_setup.sh onPrem
- Verify installed version of software:
- Target2 : Goto cd /opt/asimily/onPrem and check that the file ASIMILY_RELEASE_VER has proper version And also check the names of the jar has the same version.
- Database Update : *Target2
cd /opt/asimily/onPrem/db-schema/scripts
bash update_asimily_db.sh
Make sure you get success message
- Start the on prem modules:
- Target2
cd /opt/asimily/onPrem
bash runOnPremServer.sh
Verify using ps -ef that the jars with new version are running and not old