Scrape metrics with Metric Exporter + Prometheus Push Gatway behind NAT

Hi everyone,

Graylog version: v4.0.1

My setup:
Untitled Diagram

I followed the following document to export the metrics using the metric exporter and Prometheus Pushgateway

Because the Graylog is behind NAT device, so I used PAT to translate port 9000 and 9001 into the 2 Graylog instances inside.

I can successfully access the metrics both locally (using curl) and externally (e.g. using a browser to http://30.10.10.2:9001/api/plugins/org.graylog.plugins.metrics.prometheus/metrics).

But the Prometheus fails to pull any metrics from them. The scrape config in Prometheus is also following the document mentioned earlier

#
- job_name: 'graylog'
scrape_interval: 15s
metrics_path: '/api/plugins/org.graylog.plugins.metrics.prometheus/metrics'
basic_auth:
username: admin
password: admin
# Optional TLS configuration; see https://prometheus.io/docs/operating/configuration/#<tls_config>
#tls_config:
static_configs:
- targets: ['30.10.10.2:9000', '30.10.10.2:9001']
#

Everyone having the same experience and know how to solve it? :thinking:

Thanks a lot in advance.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.