Skip to content

Commit

Permalink
*ks: correctly define cluster:node_cpu:ratio rule (#1521)
Browse files Browse the repository at this point in the history
There was a bug in the rule imported from kube-prometheus causing the
rule not to correctly return any results. This caused the data to be
missing on the optimized dashboard from *ks clusters.

Upstream fix was here:
prometheus-operator/kube-prometheus#1628

Signed-off-by: Jacob Baungard Hansen <jacobbaungard@redhat.com>
Co-authored-by: Jacob Baungard Hansen <jacobbaungard@redhat.com>
  • Loading branch information
1 parent 89d9d1c commit 27e6b21
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ spec:
record: instance:node_cpu:ratio
- expr: sum(rate(node_cpu_seconds_total{mode!="idle",mode!="iowait",mode!="steal"}[5m]))
record: cluster:node_cpu:sum_rate5m
- expr: cluster:node_cpu_seconds_total:rate5m / count(sum(node_cpu_seconds_total)
- expr: cluster:node_cpu:sum_rate5m / count(sum(node_cpu_seconds_total)
BY (instance, cpu))
record: cluster:node_cpu:ratio

0 comments on commit 27e6b21

Please sign in to comment.