Prometheus CPU is pegged at 100% but ingestion is flat
IntermediateTroubleshootingPrometheus storage, memory and cardinality
Answer
Likely causes → Expensive queries: dashboards auto-refreshing every 5s over 7d, regex matchers like {__name__=~".*"}, or slow rule groups.
Diagnose → Enable --query.active-query-tracker/query log (global.query_log_file), then:
topk(10, prometheus_rule_group_last_duration_seconds)
rate(prometheus_engine_query_duration_seconds_sum[5m])
Fix → Increase dashboard refresh intervals, replace hot queries with recording rules, and kill bad ones.
Prevent → Put a query frontend (Thanos/Mimir) with caching in front for heavy dashboards.
More on Prometheus storage, memory and cardinality
Prometheus pod restarts with `OOMKilled` every few hoursIntermediateA query fails with `query processing would load too many samples into memory in query execution`IntermediateHead series jumped from 2M to 9M after a deployAdvancedPrometheus logs `opening storage failed: ... unexpected EOF` / `corruption in segment` and won't startAdvancedPrometheus is in CrashLoopBackOff with `no space left on device`BeginnerPrometheus takes 15 minutes to become ready after a restartAdvanced