Using the Zabbix Observer functionality, you can load monitored servers and their
associated network resources, and then visualize this data as a topology view in the Agile Service
Manager UI. It is installed as part of the core installation procedure.
Before you begin
The Zabbix Observer supports Zabbix Versions 4.0.3, 6.0.3 and 6.4.11.
Ensure you have the Zabbix server details to hand, such as the username, password and SSL
TrustStore.
Remember: Swagger documentation for the observer is available at the following default
location: https://<your
host>/1.0/zabbix-observer/swagger
About this task
A Zabbix Observer job extracts server information and its associated network resources from
Zabbix via REST RPC. The Observer loads and updates the resources and their relationships within the
Netcool Agile Service Manager core topology service.
zabbix_observer_common.sh
- The configuration file you use to customize Zabbix Observer settings.
- The parameters defined here are then used by the
zabbix_observer_load_start.sh
script to trigger the Zabbix Observer jobs.
-
Tip: Alternatively, you can set the appropriate environment variables. If an environment
variable is set, it takes precedence over the config file settings.
You define and start the following job. You must edit the parameters in the config file before
running this job.
- Full Topology Upload job
- A transient (one-off) job that loads all requested topology data.
- This job is started by the zabbix_observer_load_start.sh script.
Procedure
To edit the parameters in the config file
-
Open the zabbix_observer_common.sh config file and edit (at least) the
following parameters:
- hostname
- Zabbix hostname or ipaddreess
- username
- Zabbix user name
- password
- Zabbix user password.
- Must be supplied in encrypted format.
For encryption: Run the
encrypt_password.sh
script in the
ASM_HOME/bin directory:
./bin/encrypt_password.sh
Enter
and then confirm the password. The encryption utility will return an encrypted
version.
- certificate
- Optional certificate name. If provided, then a certificate file with the same name must exist in
the $ASM/security directory.
- ssl_truststore_file
- Zabbix SSL trust store file for HTTPS authentication
- JKS is the supported format and the file is relative to $ASM_HOME/security
- truststore_password
- Password to decrypt and encrypt Zabbix SSL trust store file
- Must be encrypted.
For encryption: Run the
encrypt_password.sh
script in the
ASM_HOME/bin directory:
./bin/encrypt_password.sh
Enter
and then confirm the password. The encryption utility will return an encrypted
version.
- connect_read_timeout_ms
- Connection timeout in milliseconds (ms), for example '5000'.
To acquire Zabbix SSL certificate and build SSL
truststore
-
Use the following command to use OpenSSL to connect to Zabbix, and extract an SSL Certificate
from Zabbix to a <certificate_file_name>.crt file.
echo -n | openssl s_client -connect {Zabbix IpAddress}:{SSL port | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' > ./{certificate_file_name}.crt
-
Use the following Java keytool command to import the Zabbix certificate file into a keystore
and encrypt the keystore with a given password.
keytool -import -v -trustcacerts -alias {Zabbix Hostname} -file {certificate_file_name}.crt -keystore {keystore file name} -storepass {your plain text password to encrypt keystore}
Tip: You will need the following encryption information when editing
zabbix_observer_common.sh
Table 1. Encryption parameters required for
zabbix_observer_common.sh
keystore parameter |
zabbix_observer_common.sh parameter |
keystore password |
truststore_password |
keystore file name |
ssl_truststore_file |
-
Copy the keystore file (
{keystore file name}
) to the
$ASM_HOME/security directory to complete the SSL setup.
To start the Load job
-
To start the Zabbix Observer Full Topology Upload job, use the following command:
$ASM_HOME/bin/zabbix_observer_load_start.sh
This job loads all requested topology data. Run this job whenever you need Zabbix
topology data refreshed.
What to do next
You can also use the following scripts:
- zabbix_observer_query_stop.sh
- Stops the Full Topology Upload job
- zabbix_observer_job_list.sh
- Lists the status of current jobs
- zabbix_observer_log_level.sh
- Sets the log level
Remember: As an alternative to being configured using the Observer Configuration
UI, observer jobs have scripts to start and stop all available jobs, to list the status of a current
job, and to set its logging levels. These scripts can be run with -h or
--help to display help information, and with -v or
--verbose to print out the details of the actions performed by the script,
including the full cURL command. For the on-prem version of Agile Service Manager, observer scripts
are configured for specific jobs by editing the script configuration files.