Single Server Docker Deployment (Simple Install)
This article details how to deploy the Metric Insights application on a single server. Because this is a non-orchestrated deployment (meaning there is no automated management of the containers), it is called 'Simple Install'.
PREREQUISITES:
For servers without outbound access, the host machine must have the following packages installed manually to support the application:
-
docker-ce v18+
- for RHEL7, docker-ce v19.03.14
- docker-compose v1.29.2+
- python v2/v3
For servers with outbound access, the packages above are installed by the Metric Insights installer automatically.
Please ensure enough disk space is available for the following directories (if configured as separate partitions), as mentioned in What are the system requirements for a Metric Insights server?
- /var/lib
- /opt or /app
- /home
- /tmp
Metric Insights v6.x can be installed on the following Operating Systems (any OS with Linux kernel >= 3.10):
- RHEL 7,8,9
- CentOS 7
- Oracle Linux 7
- Ubuntu 18.04, 20.04, 24.04
- NOTE: Ubuntu 18.04 is no longer supported in MI 6.4.2
- Debian 9,10,11
- NOTE: Debian 9 is no longer supported in MI 6.4.2
- NOTE: Debian 11 is supported starting with MI 6.3.1 and beyond
- Amazon Linux 2, Amazon Linux 2023
Simple Installation Architecture
The deployment scheme consists of the following services deployed as individual containers (1 service per container):
Required services:
- Web Master
- Web Slave
- Data Analyzer
- Data Processor
- Seed
- MySQL
- Monitoring
- Redis
Optional services:
- Remote Data Processor (for BI Tools that require integrating from a Windows environment instead of Linux)
If you are using a Firewall on the Linux machine, the following ports are necessary for Metric Insights to work correctly:
- 80, 443 - HTTP and HTTPS ports for the Web Application (by default redirection to 443)
- 2550 - TCP port for the Data Processor service
- 2551 - TCP port for the Seed service
- 3306 - MySQL port for external access to the database
- 8080, 8443 - HTTP and HTTPS ports for the REST API Data Processor Service (only one port is enabled at one time)
- 8081 - TCP port for the Monitoring service (separate GUI service that admins can use to monitor the health of the application containers in a browser)
1. Connect to the Server via SSH
The Metric Insights application must be installed as user root or as a user with sudo privileges (added to the wheel or sudo group, thereby included in the sudoers list). The Docker daemon binds to a Unix socket instead of a TCP port, therefore Unix sockets are owned by user root and accessible by users with sudo privileges.
Connect to the server using ssh root@<server_ip>.
2. Download the Installation Package of the Metric Insights Application
- Depending on the version, you are provided with a link to the corresponding installation package
- Enter Username and Password that are provided by the Metric Insights support team
- Confirm the agreement with the Terms and Conditions of the Metric Insights usage
- [Submit]. After you click the button, the .tar.gz archive with all Docker images and binaries will be downloaded to the local host.
3. Unzip the Archive and Download it to the Server
Typcially, the Metric Insights installation package is uploaded to the server as a tar ball file as in MetricInsights-Installer-vX.X.X-Full.tar.gz
.
- When this tar ball has been placed on the server, please unzip the tar ball with the command
tar -xvf MetricInsights-Installer-vX.X.X-Full.tar.gz
. - Once the tar ball file has been unzipped, then please go inside the installer directory with the command
cd MetricInsights-Installer-vX.X.X-Full
- Once inside the installer directory, proceed to Step 4 below
The installation package contains the following folders and files:
Folder/file title | Name |
---|---|
base | Folder with default /opt/mi file system for the Metric Insights application. |
data | Folder with binaries and miscellaneous data. |
scripts | Folder with a set of auxiliary scripts. |
utils | Folder with common libraries used by installer.ry. |
build.propertis | File that contains the Metric Insights components versions. |
installer | Python script that initializes the deployment process of the Metric Insights application. |
readme | Markdown file with the information required to deploy the application and understand the Patcher tool. |
uninstaller | Python script that uninstalls the Metric Insights application. |
4. Deploy the Metric Insights Application
It is very important to set a correct timezone for the application when running the installer using the --timezone
parameter.
If a database is running on a remote server that has timezone different from the application timezone, specify a timezone of the remote database server using the --mysql-timezone
parameter. This is an example of installing the application with MySQL running on a local host where the timezone is set to Pacific Time. Setting the --bind-address
to 0.0.0.0
is also key:
./installer.py --bind-address 0.0.0.0 --timezone 'US/Pacific' -vv
Use the ./installer.py --timezone-list
command to see the list of available timezones.
- If MySQL runs on the local host, run
sudo ./installer.py --bind-address 0.0.0.0 --timezone <timezone> -vv.
- If MySQL runs on a remote database server:
- If the remote database server has the same timezone as the Metric Insights application:
sudo ./installer.py --bind-address 0.0.0.0 --db-hostname <remote DB host> --db-user <remote DB root username> --db-password <remote DB root password> --timezone <timezone> --components web,data-analyzer,dataprocessor,seed,monitoring -vv
- If the remote database server has a different timezone than the application:
sudo ./installer.py --bind-address 0.0.0.0 --db-hostname <remote DB host> --db-user <remote DB root username> --db-password <remote DB root password> --timezone <timezone> --mysql-timezone <MySQL timezone> --components web,data-analyzer,dataprocessor,seed,monitoring -vv
- If the remote database server has the same timezone as the Metric Insights application:
Once the installation is complete, you will see a "Metric Insights v6.x.x installed successfully" message.
The "Waiting while all provision actions are completed" can take a while, so it's not so unusual. While it's running, in a separate terminal, tail /opt/mi/log/web.log
to see what it's performing.
If you need to customize some processes after the application deployment, see Configuring Custom Components article.
5. Basic Console Commands
Basic console commands can be checked by running ./installer.py -h.
The following list of utilities are available to use on the host.
Note, all of these tools become available only if the Web Component is installed.
The following list of parameters can bee used when running the installer from the Help: