Exporters are add-ons used for collecting data from services and applications in order to provide integration with tools for monitoring and real-time analytics. In Roxy-WI you can easily install the exporters for integration with Prometheus, one of the most popular and most powerful monitoring tools.

Three types of exporters are available:

In HAProxy, the support of built-in Prometheus exporter is available since version 2.4.9. You will have to upgrade HAProxy if you are using an older version.

Roxy-WI allows you to install Prometheus via the web interface. The built-in Prometheus exporters are available only if HAProxy is installed from the RPM repository via Roxy-WI. Otherwise, you will have to install an external exporter.

To install the exporters, go to Servers => Monitoring installation. The interface for installing expoters is shown in the picture below:

exporters

If your Prometheus instance is running on the same server as Roxy-WI, select the version of the exporter and the server where the exporter will be installed. Click on the Install button.

If your Prometheus instance is installed on another server, select the External Prometheus checkbox. In this case, you will have to configure Prometheus yourself. For details on Prometheus configuration, please refer to the official documentation.

Once you have finished the installation ot the exporter, it is recommended to combine the Stats page and the Prometheus endpoint into one frontend section. To do this, add the following lines to your HAProxy configuration file:

As you can see from the configuration file snipped cited above, we enable the Native HTTP representation (HTX) mode. The http-request use-service line instructs HAProxy to intercept requests for /metrics and direct them to the exporter. You can select any other path for the exporter but /metrics is the path Prometheus uses by default. If everything is configured correctly, the list of metrics will be available at http://localhost:8085/metrics.