diff --git a/pkg/monitoring/tmpl/prometheus/instance/ccp/rules.tpl b/pkg/monitoring/tmpl/prometheus/instance/ccp/rules.tpl index 85235405..0fb046e1 100644 --- a/pkg/monitoring/tmpl/prometheus/instance/ccp/rules.tpl +++ b/pkg/monitoring/tmpl/prometheus/instance/ccp/rules.tpl @@ -608,7 +608,7 @@ spec: sum by (namespace) ( sum by (namespace, pod) ( max by (namespace, pod, container) ( - kube_pod_container_resource_requests{resource="memory", job="kube-state-metrics"} + kube_pod_container_resource_requests_memory_bytes{job="kube-state-metrics"} ) * on(namespace, pod) group_left() max by (namespace, pod) ( kube_pod_status_phase{phase=~"Pending|Running"} == 1 ) @@ -619,7 +619,7 @@ spec: sum by (namespace) ( sum by (namespace, pod) ( max by (namespace, pod, container) ( - kube_pod_container_resource_requests{resource="cpu",job="kube-state-metrics"} + kube_pod_container_resource_requests_cpu_cores{job="kube-state-metrics"} ) * on(namespace, pod) group_left() max by (namespace, pod) ( kube_pod_status_phase{phase=~"Pending|Running"} == 1 ) diff --git a/pkg/monitoring/tmpl/prometheus/instance/infra/rules.tpl b/pkg/monitoring/tmpl/prometheus/instance/infra/rules.tpl index 9b53c03b..954839bc 100644 --- a/pkg/monitoring/tmpl/prometheus/instance/infra/rules.tpl +++ b/pkg/monitoring/tmpl/prometheus/instance/infra/rules.tpl @@ -608,7 +608,7 @@ spec: sum by (namespace) ( sum by (namespace, pod) ( max by (namespace, pod, container) ( - kube_pod_container_resource_requests{resource="memory", job="kube-state-metrics"} + kube_pod_container_resource_requests_memory_bytes{job="kube-state-metrics"} ) * on(namespace, pod) group_left() max by (namespace, pod) ( kube_pod_status_phase{phase=~"Pending|Running"} == 1 ) @@ -619,7 +619,7 @@ spec: sum by (namespace) ( sum by (namespace, pod) ( max by (namespace, pod, container) ( - kube_pod_container_resource_requests{resource="cpu",job="kube-state-metrics"} + kube_pod_container_resource_requests_cpu_cores{job="kube-state-metrics"} ) * on(namespace, pod) group_left() max by (namespace, pod) ( kube_pod_status_phase{phase=~"Pending|Running"} == 1 )