You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently metallb.name (e.g metallb) is used as metrics job label in prometheus rules, but the value of the job label in metallb metrics is rendered as metallb-speaker-monitor-service which causes prometheus rule to pick zero metric results during rule execution. Having metallb-speaker-monitor-service in the job label is expected since servicemonitor's jobLabel value is set app.kubernetes.io/name by default and there is no such a label in the metallb-speaker-monitor-service and for this reason it is defaulted to actual service name which is metallb-speaker-monitor-service.
Please see the jobLabel behavior here as quoted below;
jobLabel selects the label from the associated Kubernetes Service object which will be used as the job label for all metrics.
For example if jobLabel is set to foo and the Kubernetes Service object is labeled with foo: bar, then Prometheus adds the job="bar" label to all ingested metrics.
If the value of this field is empty or if the label doesn’t exist for the given Service, the job label of the metrics defaults to the name of the associated Kubernetes Service.
MetalLB Version
v0.14.5
Deployment method
Charts
Main CNI
cilium
Kubernetes Version
v1.25.14
Cluster Distribution
rancher
Describe the bug
Currently
metallb.name
(e.gmetallb
) is used as metrics job label in prometheus rules, but the value of the job label in metallb metrics is rendered asmetallb-speaker-monitor-service
which causes prometheus rule to pick zero metric results during rule execution. Havingmetallb-speaker-monitor-service
in the job label is expected since servicemonitor'sjobLabel
value is setapp.kubernetes.io/name
by default and there is no such a label in themetallb-speaker-monitor-service
and for this reason it is defaulted to actual service name which ismetallb-speaker-monitor-service
.Please see the jobLabel behavior here as quoted below;
To Reproduce
... --set prometheus.serviceMonitor.enabled=true --set prometheus.serviceAccount=prometheus-monitoring-kube-prometheus --set prometheus.namespace=monitoring
metallb_bgp_session_up{job="metallb"}
{job="metallb-speaker-monitor-service"}
Expected Behavior
The metrics in Prometheus should be in a format as shown below
not
--
Additional Context
Since the helm chart is not working as expected with the default settings, the critical alert
MetalLBBGPSessionDown
might be missedI've read and agree with the following
I've read and agree with the following
The text was updated successfully, but these errors were encountered: