Skip to main content

Prometheus Scrape plugin

The Prometheus Scrape plugin collects data from Prometheus endpoints. The Prometheus Scrape plugin must be installed on a host to begin collecting metrics.

When to use the Prometheus Scrape plugin

APEX AIOps Incident Management offers three convenient mechanisms for integration with Prometheus.

  • Use the Incident Management Prometheus Scrape plugin with an APEX AIOps Incident Management Collector, when you:

    • Want to gather and send Prometheus Scrape data to the Incident Management Events API for intelligent monitoring.

    • Don’t want to make direct outbound calls from your environment.

    • Can install an Incident Management Collector on a host in your environment and it will act as a proxy.

  • Incident Management offers two other Prometheus integrations, Prometheus Alertmanager and Prometheus Remote Write:

    • Use the Prometheus Alertmanager integration to ingest notifications from Prometheus and send them to Incident Management with automatic mapping.

    • Use the Prometheus Remote Write integration to ingest metrics from any external system that supports the Prometheus remote write protocol.

    • Use either integration when you can configure your Prometheus instance to authenticate against an Incident Management endpoint to send data to Incident Management. These integrations do not require an Incident Management Collector and you can use authentication.

Install Prometheus

To have the Incident Management Prometheus plugin scrape data from a Prometheus endpoint and send data to APEX AIOps Incident Management, install Prometheus on the systems that you want to monitor.

Install an Incident Management Collector

To use the Prometheus Scrape plugin, in your Incident Management UI:

Navigate to the Integrations > Ingestion Services > Collector tab and install an Incident Management Collector on your host. Read Installing a Linux or Mac collector or Installing a Windows collector, for detailed information about installing a collector.

  1. You can install a collector on the same host that is running Prometheus.

  2. You can install a collector on a different host and scrape data from Prometheus.

After installing a collector, go to Ingestion Services > Collectors and click on a specific collector, then select the Prometheus Scrape plugin.

Note

Do not go directly to the Plugins tab, to configure the plugin, as the plugin needs to be associated with a specific collector to work properly.

You can set up the collector plugin when you download a new Incident Management Collector, or any time afterwards when configuring an existing collector.

Configure the Prometheus Scrape plugin

When you click on your Collector > Prometheus Scrape Plugin, a pop-up panel provides links to install an Incident Management Collector or configure the Prometheus Scrape plugin.

Parameter configuration:

  1. From the Prometheus Scrape Plugin > Configuration tab, define the following Prometheus Scrape Plugin parameters::

    • Endpoints — Specify the endpoints for the configuration. The default endpoint is set to http://localhost:9100/metrics. You can use either a URL or IP address such as, such as http://somehost:someport/metrics or http://ipaddress:someport/metrics. You can also have multiple endpoints on a single machine for different types of data (one for system metrics, one for SQL, and so forth).

      Note

      Test your endpoints before specifying them, if one does not work it can prevent the plugin from collecting data from the other endpoints.

    • Scrape Interval (sec) — Set the frequency with which Incident Management monitors and ingests metrics; the default is every 15 seconds.

  2. Toggle on the Enable option on when you are ready to start plugin data ingestion.

Validate the Prometheus Scrape plugin integration

To validate the integration, you can try some of the following options:

  • Test that your endpoints are working. You may want to specify one at a time and test each one. If one endpoint is not working in a series, it can stop the others from working.

  • Test that the Prometheus Scrape Plugin Collector can listen on the specified endpoint and port number. For an easy test, install Prometheus on the same host as the plugin and use the default localhost provided in the plugin Parameter Configuration panel.

  • Check Ingestion Services > Collectors > Collector Logs to help troubleshoot your installation and configuration.

  • To check if Prometheus Scrape succeeded in transmitting data to the plugin:

    • In Incident Management, click Metrics and look for the endpoint to see if the Prometheus Scrape data is flowing into the plugin.

    • Check the Prometheus Metrics panel and specify one metric in the Incident Management Metrics filter to check on a particular metric.