Where can I find descriptions of Prometheus metrics? Where can I find descriptions of Prometheus metrics? kubernetes kubernetes

Where can I find descriptions of Prometheus metrics?


I found the answer for my question. yogesh's answer gave me the hint to have a look at exporters and I found the other half of the answer here.

So on Prometheus UI, there is a list of exporters and their scraped endpoints (Status > Targets). If I call one of the endpoints, the response contains a description and the type of each metric offered by the endpoint.

Call:

curl http://exporter.endpoint:9100/metrics

Sample from a response:

# HELP http_response_size_bytes The HTTP response sizes in bytes.# TYPE http_response_size_bytes summaryhttp_response_size_bytes{handler="prometheus",quantile="0.5"} 16310http_response_size_bytes{handler="prometheus",quantile="0.9"} 16326http_response_size_bytes{handler="prometheus",quantile="0.99"} 16337http_response_size_bytes_sum{handler="prometheus"} 1.46828673e+09http_response_size_bytes_count{handler="prometheus"} 90835# HELP node_arp_entries ARP entries by device# TYPE node_arp_entries gaugenode_arp_entries{device="cali6b3dc03715a"} 1node_arp_entries{device="eth0"} 15

It wasn't trivial for me how to get this done. I logged into the cluster and I found curl didn't get any response for any of the endpoints. The solution was to add the base of the endpoint urls to the no_proxy variable (my machine and the server are both sitting behind the corporate proxy).

But anyway, this is how one can read the description of the Prometheus metrics.


I think you want to find "which metric does what" which is irrespective of kubernetes.

Prometheus will get data from exporter and store in its database, So you have to ask this question to your exporter which is exporting the matrix.

Eq. You can get basic CPU memory from node exporter. You can find all matrix exposed by Node exported in the below link.
https://github.com/prometheus/node_exporter

Now the question remains which is exporting which matrix that can be found from the target in Prometheus UI.


You can fetch metadata of metric with following curl expression:

url=http://urpromhost:9090curl -G $url/api/v1/targets/metadata \     --data-urlencode 'metric=metricname' \     --data-urlencode 'match_target={}'