Prometheus and PromQL 3 · Rates and aggregation
CPU used as a percentage
A common node_exporter query for host CPU use.
100 - (avg by (instance) (rate(node_cpu_seconds_total{mode="idle"}[5m])) * 100)
Official Prometheus and PromQL 3 documentation
More rates and aggregation commands
- Per-second rate of a counter
- Total increase over a window
- Aggregate across series
- Error ratio
- 95th percentile latency
- Top N series
All rates and aggregation commands · Prometheus and PromQL 3 cheatsheet