3.07 Scraping metrics to Prometheus - MartinWong06/grafana GitHub Wiki

Prepare prometheus.yml file

Configure prometheus.yml to scraping metric to Prometheus

standard file path /etc/prometheus/prometheus.yml

prometheus.yml

Example: Scrap other machine in same network

prometheus_2nd_node.yml

Job name: Please provide identical job name in the yml, however a single job name can be used by multiple hosts and differentiated by the use of labels.

Example: https://github.com/MartinWong06/grafana/blob/main/prometheus_job_example.yaml
This simplified example illustrates how Prometheus can monitor the same job ('simple_job') on different hosts ('host1', 'host2', 'host3', 'host4').

Advance Topic
Relabel Config

⚠️ **GitHub.com Fallback** ⚠️