---
title: APM using OpenTelemetry Collector with Kubernetes
description: Correlate pod and host metrics with traces and logs in Coralogix APM by shipping Kubernetes resource attributes from the OpenTelemetry Collector.
url: https://coralogix.com/docs/opentelemetry/integrations/apm-kubernetes/
product: apm
feature: OTel Agent
feature_id: apm-otel-agent
feature_identifier: apm/apm-otel-agent
last_updated: '2026-09-03'
---

# APM using OpenTelemetry Collector with Kubernetes

Coralogix [application performance monitoring](https://coralogix.com/docs/user-guides/apm/getting-started/apm-onboarding-tutorial.md) can attach pod and host context to every pillar of your [observability](https://coralogix.com/blog/what-is-observability/) data, so a slow span shows you the pod that served it and what that pod's memory was doing at the time.

The mechanism is resource attributes: the OpenTelemetry Collector's Kubernetes processor stamps each signal with the pod and node it came from, and Coralogix joins on those.

## What you need

* [Kubernetes](https://kubernetes.io/) with [kubectl](https://kubernetes.io/docs/tasks/tools/#kubectl).
* [Helm](https://helm.sh/) installed and configured.
* A [metrics bucket](https://coralogix.com/docs/user-guides/data-flow/s3-archive/connect-s3-archive.md).
* [OpenTelemetry for Kubernetes](https://coralogix.com/docs/opentelemetry/kubernetes-observability/kubernetes-complete-observability-basic-configuration.md) installed and configured.

Note

Send logs, metrics, **and** traces. APM correlates across all three, with any one missing, the joins this page relies on do not resolve.

## View the correlated data

1

<!-- -->

.

Open a trace

Select **Explore**, then **Tracing**, and select the trace you want to investigate.

2

<!-- -->

.

Open the pod and host panels

In the span detail pane, select the **POD** and **HOST** tabs, alongside **RELATED LOGS** and **SPAN LOGS**. Both **Spans view** and **Dependencies view** carry them.

[![Coralogix trace waterfall with the HOST tab open, showing memory used, total, free, and available charts for the node](/docs/assets/images/Untitled-23-1024x571-b0ae47c72acf4dcee15cb833c4d3cb39.webp)](https://coralogix.com/docs/assets/images/Untitled-23-1024x571-b0ae47c72acf4dcee15cb833c4d3cb39.webp)

Shows a span alongside the memory behavior of the node that ran it.

## Validate the correlation

If any check below returns empty or unexpected results, the data being sent needs review.

### Resource attributes on spans

Coralogix APM looks for `k8s.pod.name` and `k8s.node.name` on each span and uses them to find matching metrics and logs. If either is unset, correlation does not work.

Open a span in the Tracing UI and expand its resources.

[![Coralogix span resources panel listing Kubernetes deployment, namespace, node name, pod IP, pod name, start time, and UID](/docs/assets/images/Screenshot-2023-03-22-at-15.20.38-1024x726-f38eaa6573640aaa8a0fb2ede5974dde.webp)](https://coralogix.com/docs/assets/images/Screenshot-2023-03-22-at-15.20.38-1024x726-f38eaa6573640aaa8a0fb2ede5974dde.webp)

Shows the attribute set a correctly configured Collector produces.

### Host metrics

APM needs metrics from [Kube State Metrics](https://github.com/kubernetes/kube-state-metrics) and the [Node Exporter](https://github.com/prometheus/node_exporter). Both ship with the [Coralogix Prometheus Operator](https://github.com/coralogix/telemetry-shippers/tree/master/metrics/prometheus/operator).

Run these in the Coralogix Grafana console, in order, each one's output feeds the next.

1

<!-- -->

.

Check Kube State Metrics reach the node

Confirm the KSM labels match the `k8s.node.name` attribute on your spans. The result carries an `internal_ip` label you need next.

```
kube_node_info{node="<your node name>"}
```

2

<!-- -->

.

Check Node Exporter metrics

Use the `internal_ip` from the previous result:

```
count(node_cpu_seconds_total{instance=~"<internal_ip>.+"}) by (instance)
```

3

<!-- -->

.

Check pod metrics

Confirm pod metrics arrive from KSM, and that the Collector's own pod metrics arrive in the expected format:

```
kube_pod_info{pod=~"<partialpodname>.*"}
```

```
k8s_pod_cpu_time_total{k8s_pod_name=~"<partialpodname>.*"}
```

## Related resources

[Kubernetes complete observability: basic configuration](https://coralogix.com/docs/opentelemetry/kubernetes-observability/kubernetes-complete-observability-basic-configuration.md)[APM onboarding tutorial](https://coralogix.com/docs/user-guides/apm/getting-started/apm-onboarding-tutorial.md)[Kubernetes observability troubleshooting](https://coralogix.com/docs/opentelemetry/kubernetes-observability/troubleshooting.md)
