Service Status

Dashboard

Monitoring service status by check service tcp port via prometheus blackbox exporter
Last updated: a year ago

Start with Grafana Cloud and the new FREE tier. Includes 10K series Prometheus or Graphite Metrics and 50gb Loki Logs

Downloads: 649

Reviews: 0

  • BRcE4VdD92.png
    BRcE4VdD92.png

Summary

Monitoring service status by check service tcp port via prometheus blackbox exporter

Dependencies

Configure

Ensure that the tcp_connect module of blackbox_exporter is enabled.

blackbox.yml

modules:
  http_2xx:
    prober: http
#  http_post_2xx:
#    prober: http
#    http:
#      method: POST
  tcp_connect:
    prober: tcp

Prometheus.yml

scrape_configs:
  - job_name: "blackbox-83"
    metrics_path: /probe
    params:
      module: [tcp_connect]
    file_sd_configs:
    - files:
      - "/opt/prometheus/file_sd/services.yml"
    relabel_configs:
      - source_labels: [__address__]
        target_label: __param_target
      - source_labels: [__param_target]
        target_label: instance
      - target_label: __address__
        replacement: 172.20.3.223:9115

services.yml

- targets:
  - 172.20.3.83:9600
  - 172.20.3.84:9600
  - 172.20.3.85:9600
  labels:
    group: catcher
- targets:
  - 172.20.3.83:13660
  labels:
    group: datahub
Dependencies: