List all metric names
Count total metric names and preview first 20
curl -s http://prometheus:9090/api/v1/label/__name__/values | jq '.data | length, .[0:20]'
- tool
- prometheus30 commands
- tags
- prometheusdebug
More prometheus commands
-
count by (job) ({__name__=~".+"})PromQL: count active time series grouped by job label
-
amtool silence add alertname=HighMemory --duration=2h --comment='Investigating'Create an Alertmanager silence for 2 hours
-
curl -s http://prometheus:9090/api/v1/status/tsdb | jq '{head_chunks: .data.headStats.numChunks, series: .data.headStats.numSeries}'View TSDB head stats: chunks and active series
-
histogram_quantile(0.95, sum by(le,job)(rate(http_request_duration_seconds_bucket[5m])))p95 latency per job; note: always aggregate _bucket by le before histogram_quantile
-
predict_linear(node_filesystem_avail_bytes{mountpoint="/"}[6h], 4*3600) < 0alert when linear trend predicts disk full within 4h based on last 6h