From e9ca29f0cabb906927296bc8ef7457fac49c0dea Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Wed, 15 Dec 2021 12:22:20 -0800 Subject: [PATCH] CONVENTIONS: Update CPU query sum_irate Catching up with [1], which landed in OpenShift 4.9 and later via [2]. [1]: https://github.com/kubernetes-monitoring/kubernetes-mixin/pull/619 [2]: https://github.com/openshift/cluster-monitoring-operator/pull/1214/files#diff-3125af8c4a74a5a372c15a821e3c53b7f5710c3ebd5af1fb05f4d7294e2f1afdL529 --- CONVENTIONS.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CONVENTIONS.md b/CONVENTIONS.md index 8207bcd54d..c7ca85045f 100644 --- a/CONVENTIONS.md +++ b/CONVENTIONS.md @@ -470,9 +470,9 @@ for all containers in the `openshift-monitoring` namespace: # CPU request / usage of the SDN container scalar( max(kube_pod_container_resource_requests{namespace="openshift-sdn", container="sdn", resource="cpu"}) / - max(max_over_time(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{namespace="openshift-sdn", container="sdn"}[120m]))) * + max(max_over_time(node_namespace_pod_container:container_cpu_usage_seconds_total:sum_irate{namespace="openshift-sdn", container="sdn"}[120m]))) * # CPU usage of each container in the openshift-monitoring namespace -max by (pod, container) (node_namespace_pod_container:container_cpu_usage_seconds_total:sum_rate{namespace="openshift-monitoring"}) +max by (pod, container) (node_namespace_pod_container:container_cpu_usage_seconds_total:sum_irate{namespace="openshift-monitoring"}) ``` > Please note that pods which run on control-plane nodes must use the etcd container as their baseline.