Creating Zabbix integrations
A Zabbix integration collects different types of metrics, including live and historical data, to monitor and analyze application performance. It gathers metrics at scheduled intervals from the Zabbix server, and sends data to the gRPC server as cloud events. IBM Cloud Pak for AIOps uses this metric data to identify deviations from the normal behavior and report anomalies. The AI algorithm that analyzes Zabbix data is Metric anomaly detection.
For more information about the Zabbix integrations, see the following sections:
- Before you begin
- Creating Zabbix integrations
- Enabling and disabling Zabbix integrations
- Editing Zabbix integrations
- Deleting Zabbix integrations
For more information about HTTP headers for the various credential types, see HTTP headers for credential types.
Before you begin
Before you create a Zabbix integration, complete the following steps:
- Install Zabbix v6.0
- Add and configure hosts in the Zabbix server
Note: The Zabbix integration does not support the Zabbix server 6.4 version (or newer).
For more information about installing Zabbix and setting up host, see the Installation and the Quickstart sections in the Zabbix documentation.
To create a Zabbix integration, you must have the following information:
- Endpoint
- Username and Password or API Token
Creating Zabbix integrations
To create a Zabbix integration, complete the following steps:
-
Log in to IBM Cloud Pak for AIOps console.
-
Expand the navigation menu (four horizontal bars), then click Define > Integrations.
-
On the Integrations page, click Add integration.
-
From the list of available integrations, find and click the Zabbix tile.
Note: If you do not immediately see the integration that you want to create, you can filter the tiles by type of integration. Click the type of integration that you want in the Category section, or alternatively start typing the integration name in the searchbar and the corresponding tile appears.
-
On the side-panel, review the instructions and select your required options from the following sections:
-
Select the data types that you need to collect: Select the relevant checkbox for Metrics, or Topology. You can select either Metrics or Topology but not both at the same time.
-
Specify where you'd like to install the integration: Select between the Cluster running Cloud Pak for AIOps or Self-hosted with network visibility to Zabbix radio buttons.
-
Select Cloud Pak for AIOps integration: You can leave this at the default Use the integration recommended by Cloud Pak for AIOps, or change it to just Metrics, or Topology.
The below steps presuppose you select Metrics but if you do select Topology then you will be brought to a New observer job page. The Zabbix observer will read data from a Zabbix instance through its REST APIs and load a topology into Cloud Pak for AIOps. For more information, see Configuring a Zabbix observer job.
-
-
Click Next.
Figure. Configure Zabbix integration -
On the side-panel, review the information and when ready to continue, click Get Started.
Figure. Get started -
On the Add integration page, define the general integration details:
-
Name: Create a unique name for your integration.
Note: Currently, the integration name field only supports alphanumeric characters and excludes spaces and other special characters.
-
Description (optional): Provide a description for your integration.
-
Endpoint: Both http and https urls will be supported by the endpoint (for example, http://<Zabbix-server-hostname>/zabbix/api_jsonrpc.php or https://<Zabbix-server-hostname>/api_jsonrpc.php). In this case you can enter the following endpoint for your integration:
<protocol>://<Zabbix-server-hostname>/zabbix/api_jsonrpc.php
where
protocol
is HTTP or HTTPS andzabbix
is the path toapi_jsonrpc.php
file, which is located in the front-end directory. -
Authentication type: Select between Username/Password or API Token.
-
Username: Enter a username for the Zabbix integration.
-
Password: Enter a password for the Zabbix integration.
-
API Token: Enter an API token for the integration.
Figure. Create Zabbix integration
Support for Zabbix v5.x
There is a known limitation whereby the Username/Password authentication does not work for Zabbix v5.x. You must use the API Token authentication method instead.
The following sample steps show how to retrieve the API authentication token
$auth
from the Zabbix server. Ensure that the auto-logout option is not selected for the Zabbix user.% url=http://zabbixserverv5.com/zabbix/api_jsonrpc.php % auth=$(curl -s -X POST -H 'Content-Type: application/json-rpc' \ -d ' {"jsonrpc":"2.0","method":"user.login","params": {"user":"myApiUser","password":"myApiPassword"} , "id":1,"auth":null} ' $url | \ jq -r .result ) % echo $auth 3398cacccfa6e8xxx
Note: For this example, you must have
curl
andjq
installed.For more information see Zabbix documentation.
-
-
-
To verify the SSL/TLS configuration:
- Set the Verify the SSL/TLS certificate for the REST service toggle to on.
- Either enter a CA certificate used to verify the SSL/TLS integration to the REST service or click Fetch SSL certificate to fetch the certificate automatically.
-
Click Test connection.
Note: After you click Test connection, wait for the test to succeed before you continue to the next step. It might take some time. If the test fails, verify your credentials, and ensure that the server is up and running. However, you can still move to the metric selection page.
- Deployment options: Select one of the options, Local or Remote.
-
Local: This option deploys the integration in the same cluster where IBM Cloud Pak for AIOps is installed.
-
Remote: This option deploys it in your chosen location. After you add the integration, you get a bootstrap command to finish the deployment.
Figure. Test connection
-
-
Click Next.
-
On the Configure Proxy (Optional) page complete the following fields:
-
Connect to Zabbix via a proxy server: Set the toggle button to on.
-
URL of HTTP proxy server: Enter a URL for the HTTP proxy server.
-
Port number of proxy server: Enter a port. The default is 8080.
Note: Only unauthenticated HTTP proxy is supported.
-
-
Click Next.
-
Enter Collect metric data information:
-
Enable data collection: Toggle the switch to the on position. However, if you disable data flow, a new integration is created, but metrics are not collected.
-
Select templates: You can either select all templates or choose the templates that you want to apply to the hosts. Only templates that have metrics will be shown in the UI.
- To select all templates, click Select all templates.
- To clear all selection, click Unselect all templates.
- To choose the required templates, select the checkbox of the templates you require from the drop-down list.
Note: You must select templates appropriate to the hosts. This is because if an item from the template is not available for the host, the integration cannot pull data for that item.
For more information about performance considerations for metric data collection, see Performance considerations for metric data collection.
-
Search and select the required metrics: After the templates are loaded, the filter table displays all the associated built-in metrics of the selected templates. These metrics are preselected. You can search through and change the selection, if required.
-
To select a metric, click the checkbox of the required metric.
-
To remove a selected metric, clear its corresponding checkbox.
-
To select or clear all selected metrics, click Built-in metrics name. Alternatively, you can click Select all or Unselect all on the filter table header.
-
To change the size of the page that lists the built-metrics, select a number from the Items per page list at the end of the table.
-
To navigate through the pages to see all the metrics, click the next page or previous page arrows.
Figure. Collect metric data
-
-
Hosts: The hosts are preselected on the load itself. To undo the selection, clear the checkbox of the hostname from the drop-down list.
Note: If any of the hosts are not available, a notification is displayed. Unselect the hosts that are not available or ensure that all hosts are working in the Zabbix target system before you create your Zabbix integration. If a host goes down after you create the integration, edit and remove the host in your integration.
Note: Zabbix organizes hosts based on their IP address. Therefore, if two hosts have the same IP address, then selecting one of these hosts results in both hosts getting selected.
-
Base parallelism: Specify the number of requests that can run in parallel. The default value is 3.
-
History Span (minute): Enter a value in minutes. The value represents the time interval for live or historical data collection. The default value is 1.
Figure. Create Zabbix integration hosts -
Select historical or live data collection:
Note: If you choose to collect only live data, you cannot collect historical data after the live data collection starts.
-
Live data collection: To collect live data, complete the following steps: * Only collect live data once the integration is established: Select the checkbox. * Integration interval in minutes for live metrics (1-60): Enter a value in minutes. The value represents the frequency at which data is sampled for live metrics. The default value is 5.
-
Historical data collection: If you do not select live data collection, then historical data metrics are automatically collected. To collect historical data, complete the following steps:
- Start date and time: Select the start date from the calendar and enter the time in the hh:mm format (hours and minutes).
Note: The start date must not exceed 31 days from the present as the maximum time period for historical data collection is 31 days. The recommended time period is two weeks.
-
Time zone: Select your time zone from the drop-down list.
-
End date and time: Click Add end date and select a date from the calendar. Also, enter the time in the hh:mm format (hours and minutes). If you want to remove an end date, click Remove end date.
Note: If you do not set an end date, IBM Cloud Pak for AIOps collects historical data from the specified start date and continues with live data collection. Therefore, you must specify the integration interval for live metrics.
-
Integration interval in minutes for live metrics (1-60): Enter a value in minutes. The value depicts the frequency at which data is sampled for live metrics. The default value is 5.
- Click Done.
You created a Zabbix integration in your instance.
Enabling and disabling Zabbix integrations
If you didn't enable your data collection during creation, you can enable your integration afterward. You can also disable a previously enabled integration the same way. To enable or disable a created integration, complete the following steps:
-
Log in to IBM Cloud Pak for AIOps console.
-
Expand the navigation menu (four horizontal bars), then click Define > Integrations.
-
On the Manage integrations tab of the Integrations page, click the Zabbix integration type.
-
Click the integration that you want to enable or disable.
-
Set Enable data collection to On or Off to enable or disable log data collection. Disabling data collection for an integration does not delete the integration.
You enabled or disabled your integration. For more information about deleting a integration, see Deleting Zabbix integrations.
Editing Zabbix integrations
After you create your integration, your can edit the integration. For example, if you want to change the time interval of how often your job runs, you can edit it. To edit a integration, complete the following steps:
-
Log in to IBM Cloud Pak for AIOps console.
-
Expand the navigation menu (four horizontal bars), then click Define > Integrations.
-
Click the Zabbix integration type on the Manage integrations tab of the Integrations page.
-
On the Zabbix integrations page, click the name of the integration that you want to edit. Alternatively, you can click the options menu (three vertical dots) for the integration and click Edit. The integration configuration opens.
-
Edit your integration. Click Next to go through the integration configuration pages. Click Save when you are done editing.
You edited your integration.
Deleting Zabbix integrations
If you no longer need your zabbix integration and want to delete it entirely, you can delete the integration from the console.
To delete a integration, complete the following steps:
-
Log in to IBM Cloud Pak for AIOps console.
-
Expand the navigation menu (four horizontal bars), then click Define > Integrations.
-
Click the Zabbix integration type on the Manage integrations tab of the Integrations page.
-
On the Zabbix integrations page, click the options menu (three vertical dots) for the integration that you want to delete and click Delete.
-
Enter the name of the integration to confirm that you want to delete your integration. Then, click Delete.
Your integration is deleted.