Skip to content

Deploy HEAL Agent

Deploy HEAL Agent in HEAL Agent Installation Guide.

4 min read Updated SS MR

Deploy HEAL Agent#

After creating HealAgent-<OS>-<version>.tar.gz on the HEAL server, install HEAL Agent on the target server using the steps below.

Setup the Prerequisites#

Before installing HEAL Agent, please ensure the below requirements are met on the target server.

1. Ensure the Agent Installation path is present. If not present, the script creates the directory automatically.

Note: Ensure the agent installation path is configured in Config.sh while creating the HEAL Agent package.

If the install directory path is left empty, then the non-root user's home directory (in the user's home directory, the configurations of HEAL_User will be used) will be used as the agent installation path.

2. Installation of the HEAL agents on the target server:

a. Ensure that Java 1.8 or a higher version is installed.

If Java 1.8 or above is not present on the server, the installation process can utilize the Java Runtime Environment (JRE) bundled within the HEAL Agent package.

This ensures that the HEAL agents have the necessary Java version to function correctly.

HEAL Agent Deployment Procedure#

Follow the below steps on the target server to install the HEAL agent.

1. Untar HealAgent-<OS>-<version>.tar.gz file.

tar -xvzf HealAgent-<OS>-<version>.tar.gz

2. HealAgent-<OS> directory is created, which contains Installer.sh and Config.sh files along with the other modules that the installer deploys.

Note: If you want to change the configuration data entered while creating the Agent Installer, modify the attribute values in the Config.sh file.

  1. Navigate to the HealAgent-<OS> directory and perform the steps below:

a. Ensure the JAVA_HOME is set; the error "java is not set" is displayed.

Follow the steps below to resolve the issue:

i. Set the correct JAVA_HOME.

ii. Clear the log file.

iii. Execute the prerequisites.

b. Execute the below command using root or sudo user to validate the prerequisites.

sh ./scripts/prerequisite_validator.sh $JAVA_HOME

For Example:

sh ./scripts/prerequisite_validator.sh /usr/lib/jvm/java-1.8.0/jre

Expected Output:

  • With Error:
[2024-06-14 04:05:16] [INFO ] Checking root/superuser privilege...
[2024-06-14 04:05:16] [INFO ] Running with root/superuser privilege...OK
[2024-06-14 04:05:16] [INFO ] Logging to /opt/heal/nneww_Aggent/HealAgent-Linux/logs/Installer.sh.14062024-040516.log
[2024-06-14 04:05:16] [INFO ] Installation started,AgentsInstallerVersion:,Build date:
[2024-06-14 04:05:16] [INFO ] Detected platform: Linux: x86_64
[2024-06-14 04:05:16] [INFO ] Checking disk space...
[2024-06-14 04:05:16] [INFO ] Free disk space of /home: 14GB...OK
[2024-06-14 04:05:16] [INFO ] Physical memory available...
[2024-06-14 04:05:16] [INFO ] Available memory: 2822 MB...OK
[2024-06-14 04:05:16] [INFO ] Checking Java availability at configured path...
which: no java in (/usr/lib/jvm/java-1.8.0/jre/bin)
[2024-06-14 04:05:16] [ERROR] Java not installed...NOT OK
[2024-06-14 04:05:16] [REPORT] REPORT ------------------
[2024-06-14 04:05:16] [INFO ] Prerequisite Check...NOT OK
[2024-06-14 04:05:16] [ERROR] Java not installed...NOT OK
./scripts/prerequisite_validator.sh: line 516: $REPORT_FILE: ambiguous redirect

To fix the above error, do not provide a complete path of Java, provide the path as below:

sh ./prerequisite_validator.sh /usr
  • Without Error:
[2024-02-06 11:59:21] [INFO] Checking root/superuser privilege...
[2024-02-06 11:59:21] [INFO] Running with root/superuser privilege...OK
[2024-02-06 11:59:21] [INFO] Logging to /opt/heal/AgentInstaller/HealAgent-Linux/logs/Installer.sh.06022024-115921.log
[2024-02-06 11:59:21] [INFO] Installation started,AgentsInstallerVersion:,Build date:
[2024-02-06 11:59:21] [INFO] Detected platform: Linux: x86_64
[2024-02-06 11:59:21] [INFO] Checking disk space...
[2024-02-06 11:59:22] [INFO] Free disk space of /home: 46GB...OK
[2024-02-06 11:59:22] [INFO] Physical memory available...
[2024-02-06 11:59:22] [INFO] Available memory: 4064 MB...OK
[2024-02-06 11:59:22] [INFO] Checking Java availability at configured path...
[2024-02-06 11:59:22] [INFO] Using Java from /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.362.b08-1.el7_9.x86_64/jre...OK
[2024-02-06 11:59:22] [INFO] Checking Java version...
[2024-02-06 11:59:22] [INFO] Detected 1.8 Java and given Java is 64 Bit...OK
[2024-02-06 11:59:22] [INFO] test_1 group is already available...OK
[2024-02-06 11:59:22] [INFO] test_1 user is already available...OK
[2024-02-06 11:59:22] [REPORT] REPORT ------------------
./scripts/prerequisite_validator.sh: line 519: $REPORT_FILE: ambiguous redirect
[2024-02-06 11:59:22] [INFO] Pre-requites check success. Proceeding with agent installation.

Note:
1. If the prerequisite conditions are met, the script will execute successfully and display 'Pre-requites check success. Proceeding with agent installation...' If not, it will display an error message and exit.
2. Clear the log file before executing the command again.

4. The `monitor-jvm` is supported only for Linux's HealAgent.

Refer to the Monitor-JVM section.

a. Ensure that the following configurations are set to "yes" in the `Config.sh` file:

LIBHEALAGENT_ENABLE="yes"

JMX_ENABLE="yes"

JIM_ENABLE="yes"

b. If these configurations are initially set to "no" during the HealAgent installation, you can manually change these settings in the following file (post-installation):

/<path-to>/Agent/utils/monitor-jvm/config/heal.conf
  • "LIBHEALAGENT_ENABLE" corresponds to "enableLibAgent".
  • "JMX_ENABLE" corresponds to "enableJMXArgs".
  • "JIM_ENABLE" corresponds to "enableJIMArgs".

5. Execute the following command with the root or super user to initiate the script for HEAL Agent installation.

sh Installer.sh

Note: This installer script utilizes the bundled JRE from the HealAgent package which is v1.8.

If you prefer to use a different Java version that is already installed on your server, then execute the installer script as below:

sh Installer.sh <JAVA_PATH>

6. This will install all the configured HEAL Agents on the target server.

Note: Successful completion will be indicated by the "Discovering the host and services..." message in the log.