Skip to content
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

k8sattributes not functioning correctly on Azure AKS #37415

Open
kadhamecha-conga opened this issue Jan 22, 2025 · 4 comments
Open

k8sattributes not functioning correctly on Azure AKS #37415

kadhamecha-conga opened this issue Jan 22, 2025 · 4 comments
Labels
bug Something isn't working needs triage New item requiring triage processor/k8sattributes k8s Attributes processor

Comments

@kadhamecha-conga
Copy link

kadhamecha-conga commented Jan 22, 2025

Component(s)

processor/k8sattributes

What happened?

hi,

The k8sattributes is not behaving as expected when deploying resources on Azure Kubernetes Service (AKS).
The same k8sattributes and resources deploy and function correctly on Amazon EKS.

debug logs:

thanks,

Collector version

0.73

Environment information

Environment

AKS
1.30

OpenTelemetry Collector configuration

      k8sattributes:
        extract:
          labels:
          - key: app
          - key: release
          - from: pod
            key: service.namespace
            tag_name: service.namespace
          - from: pod
            key: service.name
            tag_name: service.name
          metadata:
          - k8s.pod.name
          - k8s.namespace.name
          - k8s.deployment.name
        filter:
          node_from_env_var: KUBE_NODE_NAME

Log output

`AWS
Resource attributes:
     -> service.image.version: Str(202501.2.4)
     -> service.name: Str(test-api)
     -> service.namespace: Str(testing)
     -> service.version: Str(1.0)
     -> service.instance.id: Str(9d1ae59c-6963-4bb5-9fa5-719570f952f2)
     -> k8s.cluster.name: Str(utest1)
     -> deployment.environment: Str(testenv)
     -> k8s.pod.ip: Str(10.12.116.56)
     -> k8s.pod.name: Str(test-api-7546bc9865-sn9c2)
     -> k8s.namespace.name: Str(test-app)
     -> k8s.deployment.name: Str(test-api)

AZURE
Resource attributes:
     -> service.image.version: Str(202501.1.38)
     -> service.name: Str(test-api)
     -> service.namespace: Str(testing)
     -> service.version: Str(v1)
     -> service.instance.id: Str(19ebb4c4-208b-4085-92c1-e2d9af19642f)
     -> k8s.cluster.name: Str(utest1)
     -> deployment.environment: Str(testenv1)
     -> k8s.pod.ip: Str(10.48.2.44)`

Additional context

No response

@kadhamecha-conga kadhamecha-conga added bug Something isn't working needs triage New item requiring triage labels Jan 22, 2025
@github-actions github-actions bot added the processor/k8sattributes k8s Attributes processor label Jan 22, 2025
Copy link
Contributor

Pinging code owners:

See Adding Labels via Comments if you do not have permissions to add labels yourself.

@kadhamecha-conga kadhamecha-conga changed the title k8sattributes not functioning correctly on Azure k8sattributes not functioning correctly on Azure AKS Jan 22, 2025
@bacherfl
Copy link
Contributor

Hi @kadhamecha-conga! Is this issue occurring consistently, or from time to time? This could be related to a similar issue where e.g. the deployment name of a pod was missing in the attributes: #37056 - The fix for that will be included in the next release (v0.119.0) if I'm not mistaken, so it might be worth to try again with that version as soon as it becomes available

@kadhamecha-conga
Copy link
Author

@bacherfl , k8s metadata is not at all coming.

@bacherfl
Copy link
Contributor

Ok then it is problably a different issue than the one i linked. Can you try to set the log verbosity to debug and see if there are any error messages logged by the collector?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working needs triage New item requiring triage processor/k8sattributes k8s Attributes processor
Projects
None yet
Development

No branches or pull requests

2 participants