sapcc / ntp_exporter

Prometheus exporter for NTP offset/stratum of a client
Apache License 2.0
50 stars 17 forks source link

add `exporter_version` label #12

Closed kworr closed 2 years ago

kworr commented 4 years ago

Misses two nice metrics:

ntp_version 1.1.1
ntp_up{server="127.0.0.1"} 1

Would be nice to have a track on whats installed where (I have a few hundreds of 'em) and also detect whether exporter is actually running. Right now on hosts with chrony it just returns nothing.

kworr commented 4 years ago

Ah, might be done easier:

ntp_up{exporter_version="1.1.1", server="127.0.0.1"} 1
majewsky commented 4 years ago

You can see whether the exporter is running by checking the up metric generated by Prometheus. The exact set of labels depends on your scrape config.

See here for more information: https://prometheus.io/docs/concepts/jobs_instances/ - Excerpt:

The up time series is useful for instance availability monitoring.

kworr commented 4 years ago

Um, that's nice. Thank you.

majewsky commented 4 years ago

I'll leave the issue open for the other part of the request, about adding an exporter_version label to the metrics.