-
Notifications
You must be signed in to change notification settings - Fork 72
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
Wrong Loki service_name
label value for Kubernetes pod logs
#616
Comments
service_name
label value for pod logs getting the container
service_name
label value for Kubernetes pod logs
I'm on board with this, but I could use some clarification. The list Loki provides is the list of Loki labels. How should that translate to Kubernetes labels? Meaning is |
Great question. Mapping the Kubernetes label
An interesting alternative is to map the Kubernetes label
The other log label names that Loki use to infer
WDYT? |
logic of the otel operator:
|
@petewall once we have a preference on the K8s label/metadata/spec attribute we want ot map by default, I propose that we get feedback from some users to verify our enhancement would meet their expectation. |
FYI @zeitlinger suggestion the OpenTelemetry Operator should support the |
The
service_name
label introduced in Loki v3 is populated with an erroneous value for Kubernetes pod logs collected by the Grafana Kubernetes Monitoring Helm Chart being populated with thecontainer
label value.A Kubernetes best practice is to capture the application/service name using the
app.kubernetes.io/name
Kubernetes label (see Kubernetes Documentation / ... / Recommended Labels).Som users will also be interested in defining their custom Kubernetes Label to populate the Loki
service_name
label.Loki documentation with regard to the
service_name
labelhttps://grafana.com/docs/loki/latest/setup/upgrade/#service_name-label
The text was updated successfully, but these errors were encountered: