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

Demangle not working on ebpf with rust code #3982

Open
Sh4d1 opened this issue Mar 8, 2025 · 0 comments
Open

Demangle not working on ebpf with rust code #3982

Sh4d1 opened this issue Mar 8, 2025 · 0 comments

Comments

@Sh4d1
Copy link

Sh4d1 commented Mar 8, 2025

Hello! I'm trying to setup ebpf profiles. Currently, I'm running grafana alloy with the following configuration:

discovery.kubernetes "all_pods" {
  role = "pod"
  selectors {
    field = "spec.nodeName=" + sys.env("HOSTNAME")
    role = "pod"
  }
}

discovery.relabel "local_pods" {
  targets = discovery.kubernetes.all_pods.targets
  rule {
    action = "drop"
    regex = "Succeeded|Failed"
    source_labels = ["__meta_kubernetes_pod_phase"]
  }
  rule {
    action = "replace"
    regex = "(.*)@(.*)"
    replacement = "ebpf/${1}/${2}"
    separator = "@"
    source_labels = ["__meta_kubernetes_namespace", "__meta_kubernetes_pod_container_name"]
    target_label = "service_name"
  }
}
pyroscope.ebpf "local_pods" {
  forward_to = [ pyroscope.write.endpoint.receiver ]
  targets = discovery.relabel.local_pods.output
  
  demangle = "full"
  python_enabled = false
}

pyroscope.write "endpoint" {
  endpoint {
    url = "http://pyroscope.monitoring:4040"
  }
}

This works, however my function names are still mangled, as you can see in the image:

Image

I'm running alloy 1.7.1 and pyroscope 0.12, both on kubernetes.
Posting it here since it seems the demangle happens in a package here. Let me know if you need anything else!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant