NetAgent Guide — Prerequisites
Choose the right NetAgent build and prepare the tarball before installation.
Prerequisites#
Ensure the prerequisites below are met:
1. Use the builds below, respectively:
a. For Linux, use the following build: NetAgent_<version>_Linux_x86_64.tar.gz
For Example: NetAgent_1.0.5.5_Linux_x86_64.tar.gz
b. For HP-UX, use the following build: NetAgent_<version>_HP-UX_ia64.tar.gz
For Example: NetAgent_1.0.5.5_HP-UX_ia64.tar.gz
2. Transfer the NetAgent build to the target server.
3. Execute the following command to extract the tarball:
tar -xvzf NetAgent_<version>_<OS>_<arch>.tar.gz
For Example:
- For Linux:
tar -xvzf NetAgent_1.0.5.5_Linux_x86_64.tar.gz
- For HP-UX:
tar -xvzf NetAgent_1.0.5.5_HP-UX_ia64.tar.gz
4. Ensure a folder is created as below,
After extraction, a folder named NetAgent_<version>_<OS>_<arch> will be created.
For Example:
- Linux:
NetAgent_1.0.5.5_Linux_x86_64
- HP-UX:
NetAgent_1.0.5.5_HP-UX_ia64
5. Verify Directory Contents: The NetAgent directory contains the following subfolders and files:
- Directory: NetAgent’s path
version.txt
- Directory: bin/, contains executable binaries as below:
cmdsender
forensicreader
kpireader
netagent
- Directory: config/, holds configuration files as below:
basic.properties
conf.properties
logger.properties
- Directory: scripts/, contains utility scripts:
getalllistenports.sh
install.sh
prerequisite_validator.sh
- Directory: selfheal/, includes files and scripts for self-healing operations.
lib.sh
restart.sh,
restart.sh.sig
selfhealconfig
selfheal.sh
selfheal.sh.sig
start.sh,
start.sh.sig
status.sh,
status.sh.sig
stop.sh
stop.sh.sig
- Directory: external_command/,
externalconfig
Post_Disk_Space_Check.sh
Post_Load_Average.sh
Post_Process_Count_Check.sh
Pre_Disk_Space_Check.sh
Pre_Load_Average_Check.sh
Pre_Process_Count_Check.sh
Installation of NetAgent#
Follow the steps below to install the NetAgent:
1. Obtain root or sudo access to the server where NetAgent will be installed.
2. Navigate to the scripts/ directory:
cd NetAgent_<version>_<OS>_<arch>/scripts/
3. Execute the Prerequisite Validator Script to verify system compatibility:
Note: Execute the script with the root user.
./prerequisite_validator.sh
The prerequisite script checks the following:
- User privileges for installation
- Operating system compatibility
- Available RAM
- Available disk space
- CPU core
Expected Output:
[10-12-24 10:59:43]:[Info]:-[User has enough privileges to install netagent.]
[10-12-24 10:59:43]:[Info]:-[Operating System: Linux]
[10-12-24 10:59:43]:[Info]:-[RAM: 9836 MB]
[10-12-24 10:59:43]:[Info]:-[Available Disk Space in
/opt/heal/AgentInstaller/NetAgent_Validation/NetAgent_1.0.5.5_Linux_x86_64/: 7.3G]
[10-12-24 10:59:43]:[Info]:-[CPU Cores: 6]
3. Execute the install.sh script (with sudo/root user) by passing the HEAL username and group name as arguments:
./install.sh <heal_user> <heal_group>
For Example:
./install.sh heal
Key operations performed by install.sh are as follows:
- Sets the ownership of the NetAgent directory and its contents to the specified heal_user and heal_group.
- Sets permissions to 755 for the binaries in the bin/ folder.
- Changes ownership of the netagent binary to the root user and root group.
- Sets the UID bit for the netagent binary.
Expected Output:
- With heal_user/heal_group arguments:
[10-12-24 10:50:08]:[Info]:-[Starting NetAgent installation]
[10-12-24 10:50:08]:[Info]:-[Platform recognized as Linux]
[10-12-24 10:50:08]:[Info]:-[Installing netagent...]
[10-12-24 10:50:08]:[Info]:-[NetAgent installation finished]
- Without heal_user/heal_group arguments:
[10-12-24 10:59:47]:[Info]:-[Starting NetAgent installation]
[10-12-24 10:59:47]:[Info]:-[Platform recognized as Linux]
[10-12-24 10:59:47]:[Info]:-[Installing netagent...]
[10-12-24 10:59:47]:[Warn]:-[Non-root user name not specified]
[10-12-24 10:59:47]:[Info]:-[Skipping the steps involved in changing user ownership of
netagent.]
[10-12-24 10:59:47]:[Info]:-[NetAgent installation finished]
4. Check the contents in the bin directory:
a. Execute the below command to know the current directory:
pwd
Expected Output:
/opt/HealAgents/Agent/NetAgent/NetAgent_1.0.5.5_Linux_x86_64/bin
b. Execute the below command to know the contents in the bin directory:
ll
Expected Output:
total 37352
-rwxr-xr-x. 1 test_1 9245273 Dec 5 00:20 cmdsender
-rwxr-xr-x. 1 test_1 9246657 Dec 5 00:20 forensicreader
-rwxr-xr-x. 1 test_1 9239987 Dec 5 00:20 kpireader
-rwsr-xr-x. 1 root 10507828 Dec 5 00:20 netagent