-
Notifications
You must be signed in to change notification settings - Fork 5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[kube-prometheus-stack] Fix jobLabel on prometheus-node-exporter #4851
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Monchai Onlamai <[email protected]>
Signed-off-by: Monchai Onlamai <[email protected]>
hm. I looked in that PR and I don't understand WHY is solves your issues. I'm unable to find the root cause here. Normalls, pod and service monitor taking the label from the pod and service I can see that service and pod labels are defined. |
Because prometheus-node-exporter change theirs _helper.tpl to use commonLabels instead of podLabels https://github.com/prometheus-community/helm-charts/blob/main/charts/prometheus-node-exporter/templates/_helpers.tpl#L46 In older version of prometheus-node-exporter they use podLabels.
Without jobLabel on servicemonitoring. Any metrics from node-exporter have job label in format "<release>-prometheus-node-exporter" and break many rule that still use job label "node-exporter".
|
If the Service Monitor requires that label, using prometheus.monitor.additionalLabels would enough? |
The label expected by the service monitor, |
Thats what I observe. The current config should just work. Or I'm wrong? |
This looks correct to me, unless I am missing something here. |
What this PR does / why we need it
When crate prometheus with existing chart I found that jobLabel from metrics of node exporters are not "node-exporter".
After investigation I found that we need to use commonLabels instead of podLabels.
https://github.com/prometheus-community/helm-charts/blob/main/charts/prometheus-node-exporter/templates/_helpers.tpl#L46.
Which issue this PR fixes
(optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close that issue when PR gets merged)Special notes for your reviewer
Checklist
[prometheus-couchdb-exporter]
)