Prometheus configuration

Hi to everyone, I’m new on grafana.
This my question: I need to collect data from several server with prometheus (by node_exporter).

This my simple config file with one server:


  • job_name: 'prometheus’
    • targets: [‘’]

Prometheus collect data correctly. In Grafana, after configure a datasource (according to guide line) I’ve imported the dashboard 1860 but each graphs show “N/A”. If I take a query of a graph (e.g. count(node_cpu{instance=~"$node:$port"}) ), run with error in prometheus console with {instance=~"$node:$port"}. Otherwise, without {instance=~"$node:$port"} run ok (e.g. count(node_cpu)).

Why? What’s wrong?

$node and $port are template variables in Grafana. Before Grafana send the query to Prometheus it will replace those values with the value you have selected in the dropdown on the top of the dashboards.

The dashboard your using seems to be broken. Or a missmatch with your Prometheus.
If you go into settings (the gear icon) -> template variables -> click edit template variables on the one called node and update the query to label_values(node_boot_time{job="node_exporter"}, instance) You should now be able to select the node you want to view from the top of the dashboard.