This integration is based on open source code governed by the respective communities and is not covered under the Dynatrace support policy. While we strive to assist, issues and feature requests should be reported directly to the respective project. Dynatrace cannot ensure fixes/features due to the independent nature of OSS projects.
Always use the most recent release version to ensure you have the latest patches and fixes deployed.
This page describes how to use Istio version 1.22+ with the Istio OpenTelemetry extension provider, and how to configure it to export OpenTelemetry traces to Dynatrace. This lets you monitor traffic flowing through your Istio service mesh directly in Dynatrace.
kubectl access to your clusterIn certain deployment setups, tracing with Istio version 1.22+ results in consumption of the following rate card capabilities:
When using the Dynatrace resource detector and sampler:
Without the Dynatrace resource detector and sampler: Usage incurs consumption of Custom Traces Classic (DPS) or DDUs for custom traces (Dynatrace Classic License).
You can configure Istio OpenTelemetry tracing in a standalone deployment or in combination with Dynatrace Operator.
You can use the Istio OpenTelemetry integration in combination with a Dynatrace Operator deployment with metadata enrichment and telemetry ingest endpoints enabled. Other features like OneAgent or ActiveGate are not required.
This provides the following benefits compared to standalone usage:
Prerequisites for this deployment mode:
In a standalone deployment, Istio exports traces directly to the Dynatrace OTLP API. Use this deployment mode only if you cannot deploy Dynatrace Operator.
Caveats when using standalone deployment:
Istio in ambient mode doesn't rely on Envoy proxies to route traffic, so tracing Istio traffic using the OpenTelemetry integration is not possible. If you use waypoint proxies, they would still emit traces, but the metadata would be misleading or wrong. Currently, there is no solution for end-to-end tracing in Istio ambient mode.
Ctrl+K and search for Access tokens.adaptiveTrafficManagement.read)For more information, see Dynatrace API - Tokens and authentication.
Use the following configuration as a starting point for your Istio installation, or append it to your existing Istio MeshConfig.
If you already use your own custom Mesh configuration, you need to merge its content with the provided snippet. Otherwise, you can use the snippet as-is.
apiVersion: install.istio.io/v1alpha1kind: IstioOperatorspec:components:pilot:k8s:env:- name: ENABLE_NATIVE_SIDECARSvalue: "false"meshConfig:extensionProviders:- name: dynatrace-otelopentelemetry:port: 4318service: "<dynakube-name>-telemetry-ingest.<dynatrace-operator-namespace>"http:path: "/v1/traces"timeout: 5sresource_detectors:dynatrace: {}dynatrace_sampler:tenant: "<your-tenant-id>"cluster_id: <cluster-id>http_service:service: "istio-system/<your-tenant-id>.live.dynatrace.com"port: 80http:path: "/api/v2/samplingConfiguration"timeout: 10sheaders:- name: "Authorization"value: "Api-Token <API_TOKEN>"
The configuration snippet uses the following placeholders. Replace the placeholder with the appropriate value.
<dynakube-name>-telemetry-ingest.<dynatrace-operator-namespace>: The name of your telemetry ingest service. For example, telemetry-ingest.dynatrace.svc.cluster.local<your-tenant-id>: Your Dynatrace environment ID. See environment ID to find yours.<cluster-id>: The numeric ID of your Dynatrace cluster. Use the GET /api/v1/config/clusterid API to get your cluster ID.<API_TOKEN>: The access token you generated in the previous step.Save the file as meshconfig.yaml and apply it:
istioctl install -f meshconfig.yaml
A ServiceEntry is required to communicate with the Dynatrace API.
This is needed for exporting spans and/or for obtaining sampling configuration when using the Dynatrace Sampler.
Save the following configuration as dt-serviceentry.yaml.
apiVersion: networking.istio.io/v1alpha3kind: ServiceEntrymetadata:name: dynatrace-se-otelspec:hosts:- <your-environment-id>.live.dynatrace.comports:- number: 80name: http-portprotocol: HTTPtargetPort: 443- number: 443name: https-portprotocol: HTTPSresolution: DNSlocation: MESH_EXTERNAL---apiVersion: networking.istio.io/v1alpha3kind: DestinationRulemetadata:name: dynatrace-dr-otelspec:host: <your-environment-id>.live.dynatrace.comtrafficPolicy:portLevelSettings:- port:number: 80tls:mode: SIMPLE
The configuration snippet uses the following placeholders. Replace the placeholder with the appropriate value.
<your-environment-id>: Your Dynatrace environment ID. See environment ID to find yours.Apply the configuration:
kubectl apply -f dt-serviceentry.yaml -n istio-system
As the last configuration step, use the Istio telemetry API to activate the tracing provider. Save the following configuration as dt-telemetry.yaml.
apiVersion: telemetry.istio.io/v1alpha1kind: Telemetrymetadata:name: dynatrace-telemetry-otelspec:tracing:- providers:- name: dynatrace-otel
Apply the configuration to the desired namespace:
kubectl apply -n istio-system -f dt-telemetry.yaml
Once the setup is complete and you have ingested your first data, you can verify if the traces show up on the Distributed traces page.
To also trace traffic passing through standalone Envoy proxies outside of Istio, see Configure OpenTelemetry tracing with Envoy.