How to Install Unisight 4.7.0 (dockerized version)

Marco Donauer_22436
Marco Donauer_22436
Altair Employee
edited October 2022 in Altair HPCWorks

The below instructions assume that your site has already installed Altair Grid Engine.

UniSight is used for monitoring live and historical data of Altair Grid Engine. The below instructions are to assist with the installation and setup of UniSight and assume that your site has internet connectivity.  For sites that must perform an offline installation of UniSight, email Altair Grid Engine/NavOps support at age-navops-support@altair.com.

Note: Documentation for UniSight is installed with the product.  See the UniSight documentation directory.

Install the Dockerized Version of UniSight

  1. Install CentOS 7.9 with all documented prerequisites.
  2. Become root.
  3. Install multiple alternative versions of Python:

alternatives --install /usr/bin/python python /usr/bin/python2 0

alternatives --install /usr/bin/python python /usr/bin/python2.7 1

alternatives --install /usr/bin/python python /usr/bin/python3.6 2

  1. Install the Python 3 Requests module:

pip3 install requests

  1. Email Altair Grid Engine/NavOps support at age-navops-support@altair.com to get FTP access to the Dockerized UniSight package.
  2. Download the Dockerized UniSight package to your preferred directory.
  3. Extract the dockerized UniSight package: (e.g., into /opt)

tar -xvzf dockerized-unisight-<version>-<date>.tar.gz

  1. Navigate to the UniSight directory that was just created by extracting the contents of the tar file.
  2. Run the setup script to install:

run ./setup.sh

Note: Additional packages are downloaded as part of this installation process. 

  1. Run Docker Compose:

docker-compose up -d

Note: Additional packages are downloaded. 

  1. Check if the 4nginx, GraphQL, MongoDB and UniSight containers are running:

docker ps

  1. Install UGERest.  

UGERest is required for communication between Altair Grid Engine and UniSight. Documentation for installing UGERest is available as part of the Altair Grid Engine documentation.

 

Create a Cron Job to Move Altair Grid Engine Reporting Data to UniSight

Note: Depending on your site’s Altair Grid Engine installation (i.e., user permissions, access to mounted directories, etc.), you may need to set up the cron job differently than the following instructions. 

The below instructions cover how to add the cron job to the UGE administrator’s (user = ugeadmin) crontab on the qmaster node. ugeadmin is the only user allowed to read/write the reporting files and subdirectories in $SGE_ROOT. This option was chosen because the option to add a cron job to root’s crontab on the UniSight host was not available.

  1. Copy the mv-reporting.sh script to $SGE_ROOT.

cp mv-report.sh $SGE_ROOT

Note: The mv-reporting.sh script is in the directory created after extracting the UniSight tar file (e.g., opt/unisight-<version>/)

  1. Login to the Altair Grid Engine qmaster node.
  1. Setup a cron job by editing the crontab configuration file:

crontab -e

  1. Add a new line to run mv-reporting.sh every 15 minutes:

*/15 * * * * <$SGE_ROOT>/mv-reporting.sh

  1. Save the file and exit.

 

Enable Reporting and Optional joblog in Altair Grid Engine

  1. Edit the file cluster.json in the UniSight directory.
  1. Set the following parameter values:

ugeServer:    host where UGERest is running (ex. 192.168.1.20)
ugePort:        8182 (secureRest=false) or 8183 (secureRest=true & using SSH)
user:             admin userid
pass:             admin user password
 

  1. Navigate to the UniSight directory.

 

  1. Create a cluster by running the command:

python tools/unisight_cli.py create cluster.json

 

Logging into Containers and Checking Log Files

  1. Get a list of containers:

docker ps

  1. Find the container id associated with the module.
  1. SSH into the container:

docker exec -it <container_id> /bin/bash

  1. Use the vi, cat or more commands to view the log files.
    1.  

Install the UniSight Visualization package:

  1. Download or copy the UniSight Visualization package from https://github.com/UnivaCorporation/unisight-visualizations.

Note: It is recommended to download the latest version of this package.

  1. Extract the unisight-visualizations package. (e.g., into /opt)

tar -xvzf unisight-visualizations-<version>.tar.gz

  1. Navigate to the prometheus/docker directory:

cd prometheus/docker

  1. Edit the file dockercompose.yml.
  1. Set the value of the parameter GRAPHQL_HOST to 172.17.0.1.

GRAPHQL_HOST=172.17.0.1  

  1. Run Docker Compose:

docker-compose up -d

  1. Access the UniSight dashboard using a browser and entering the following URL: http://unisight:3003.
  1. Enter the administrative credentials: admin/admin (admin/admin is the default).
  1. Setup Grafana load sensor reporting from Altair Grid Engine by executing the following command:

`qconf -sc > /tmp/sconf
echo "execd_running execd_running       INT         <=   NO NO       0       0   NO   0.000000" >> /tmp/sconf
echo "scratch_mounted scratch_mounted   INT         <=   NO NO       0       0   NO   0.000000" >> /tmp/sconf
echo "opt_total_space opt_total_space   DOUBLE     <=   NO NO       0       0   NO   0.000000" >> /tmp/sconf
echo "opt_used_space opt_used_space     DOUBLE     <=   NO NO       0       0   NO   0.000000" >> /tmp/sconf
echo "opt_avail_space opt_avail_space   DOUBLE     <=   NO NO       0       0   NO   0.000000" >> /tmp/sconf
qconf -Mc /tmp/sconf`

For Altair Grid Engine versions starting with 8.7.0 and after:

`qconf -sc > /tmp/sconf

echo "execd_running execd_running       INT         <=   NO NO       0       0   NO   0.000000    YES                  NO" >> /tmp/sconf

echo "scratch_mounted scratch_mounted   INT         <=   NO NO       0       0   NO   0.000000                  YES            NO" >> /tmp/sconf

echo "opt_total_space opt_total_space   DOUBLE     <=   NO NO       0       0   NO   0.000000                  YES            NO" >> /tmp/sconf

echo "opt_used_space opt_used_space     DOUBLE     <=   NO NO       0       0   NO   0.000000                  YES            NO" >> /tmp/sconf

echo "opt_avail_space opt_avail_space   DOUBLE     <=   NO NO       0       0   NO   0.000000                  YES            NO" >> /tmp/sconf

qconf -Mc /tmp/sconf`

 Tip: If you notice display issues on the UniSight dashboard, restarting the container may help:

docker-compose down

docker-compose up -d

Tip: Permissions on the uge-reporting directory in $SGE_ROOT may need to be modified to a+rwx to process the reporting files.