Get started with Application observability
This page provides instructions for deploying the Dynatrace Operator in application monitoring configuration to a Kubernetes cluster.
Installation options
Choose one of the installation methods that best suits your needs.
Manifest
Helm
Manifest
-
Create a
dynatrace
namespacekubectl create namespace dynatrace
-
Install Dynatrace Operator
kubectl apply -f https://github.com/Dynatrace/dynatrace-operator/releases/download/v0.13.0/kubernetes.yaml kubectl apply -f https://github.com/Dynatrace/dynatrace-operator/releases/download/v0.13.0/kubernetes-csi.yaml
Run the following command to see when Dynatrace Operator components finish initialization:
kubectl -n dynatrace wait pod --for=condition=ready --selector=app.kubernetes.io/name=dynatrace-operator,app.kubernetes.io/component=webhook --timeout=300s
-
Create secret for Access tokens
Create a secret named
dynakube
for the API token and data ingest token obtained in Tokens and permissions required.kubectl -n dynatrace create secret generic dynakube --from-literal="apiToken=<API_TOKEN>" --from-literal="dataIngestToken=<DATA_INGEST_TOKEN>"
-
Apply the DynaKube custom resource
Download the DynaKube custom resource sample for application monitoring from GitHub. In addition, you can review the available parameters or how-to-guides, and adapt the DynaKube custom resource according to your requirements.
Run the command below to apply the DynaKube custom resource, making sure to replace
<your-DynaKube-CR>
with your actual DynaKube custom resource file name. A validation webhook will provide helpful error messages if there's a problem.kubectl apply -f <your-DynaKube-CR>.yaml
-
optional Verify deployment
Verify that your DynaKube is running and all pods in your Dynatrace namespace are running and ready.
> kubectl get dynakube -n dynatrace NAME APIURL STATUS AGE dynakube https://<ENVIRONMENTID>.live.dynatrace.com/api Running 45s
In a default DynaKube configuration with CSI driver, you should see the following pods:
> kubectl get pods -n dynatrace NAME READY STATUS RESTARTS AGE dynakube-activegate-0 1/1 Running 0 50s dynatrace-oneagent-csi-driver-qxfwx 4/4 Running 0 2m49s dynatrace-oneagent-csi-driver-xk5c4 4/4 Running 0 2m49s dynatrace-oneagent-csi-driver-mz6ch 4/4 Running 0 2m49s dynatrace-operator-7dc8dc7d8c-wmh4z 1/1 Running 0 2m59s dynatrace-webhook-7bb6957fb5-l8fsq 1/1 Running 0 2m59s dynatrace-webhook-7bb6957fb5-rqnqk 1/1 Running 0 2m59s
CSI driver is optional (see Step 2). If enabled, it gets deployed as DaemonSet and results in a CSI-driver pod on each node.
-
Add a
dynatrace
projectoc adm new-project --node-selector="" dynatrace
-
Install Dynatrace Operator
oc apply -f https://github.com/Dynatrace/dynatrace-operator/releases/download/v0.13.0/openshift.yaml oc apply -f https://github.com/Dynatrace/dynatrace-operator/releases/download/v0.13.0/openshift-csi.yaml
Run the following command to see when Dynatrace Operator components finish initialization:
oc -n dynatrace wait pod --for=condition=ready --selector=app.kubernetes.io/name=dynatrace-operator,app.kubernetes.io/component=webhook --timeout=300s
-
Create secret for Access tokens
Create a secret named
dynakube
for the API token and data ingest token obtained in Tokens and permissions required.oc -n dynatrace create secret generic dynakube --from-literal="apiToken=<API_TOKEN>" --from-literal="dataIngestToken=<DATA_INGEST_TOKEN>"
-
Apply the DynaKube custom resource
Download the DynaKube custom resource sample for application monitoring from GitHub. In addition, you can review the available parameters or how-to-guides, and adapt the DynaKube custom resource according to your requirements.
Run the command below to apply the DynaKube custom resource, making sure to replace
<your-DynaKube-CR>
with your actual DynaKube custom resource file name. A validation webhook will provide helpful error messages if there's a problem.oc apply -f <your-DynaKube-CR>.yaml
-
optional Verify deployment
Verify that your DynaKube is running and all pods in your Dynatrace namespace are running and ready.
> oc get dynakube -n dynatrace NAME APIURL STATUS AGE dynakube https://<ENVIRONMENTID>.live.dynatrace.com/api Running 45s
In a default DynaKube configuration with CSI driver, you should see the following pods:
> oc get pods -n dynatrace NAME READY STATUS RESTARTS AGE dynakube-activegate-0 1/1 Running 0 50s dynatrace-oneagent-csi-driver-qxfwx 4/4 Running 0 2m49s dynatrace-oneagent-csi-driver-xk5c4 4/4 Running 0 2m49s dynatrace-oneagent-csi-driver-mz6ch 4/4 Running 0 2m49s dynatrace-operator-7dc8dc7d8c-wmh4z 1/1 Running 0 2m59s dynatrace-webhook-7bb6957fb5-l8fsq 1/1 Running 0 2m59s dynatrace-webhook-7bb6957fb5-rqnqk 1/1 Running 0 2m59s
CSI driver is optional (see Step 2). If enabled, it gets deployed as DaemonSet and results in a CSI-driver pod on each node.
Helm
Dynatrace Operator version 0.8.0+
-
Add the Dynatrace Helm repository
helm repo add dynatrace \ https://raw.githubusercontent.com/Dynatrace/dynatrace-operator/main/config/helm/repos/stable
Note that attempting to access the above URL will result in a 404 error page as it is only used internally by the Helm client.
-
Install Dynatrace Operator
You have two options:
Option 1: Install Dynatrace Operator using the default values:
helm install dynatrace-operator dynatrace/dynatrace-operator \ --set "installCRD=true" \ --set "csidriver.enabled=true" \ --atomic \ --create-namespace --namespace dynatrace
Option 2: For additional configuration to the Helm chart, edit the
values.yaml
sample from GitHub, then run the install command passing the YAML file as an argument:helm install dynatrace-operator dynatrace/dynatrace-operator \ -f values.yaml \ --atomic \ --create-namespace --namespace dynatrace
If
installCRD
is set tofalse
, you need to create the custom resource definition manually before starting the Helm installation:kubectl apply -f https://github.com/Dynatrace/dynatrace-operator/releases/download/v0.13.0/dynatrace-operator-crd.yaml
-
Create secret for Access tokens
Create a secret named
dynakube
for the API token and data ingest token obtained in Tokens and permissions required.kubectl -n dynatrace create secret generic dynakube --from-literal="apiToken=<API_TOKEN>" --from-literal="dataIngestToken=<DATA_INGEST_TOKEN>"
-
Apply the DynaKube custom resource
Download the DynaKube custom resource sample for application monitoring from GitHub. In addition, you can review the available parameters or how-to-guides, and adapt the DynaKube custom resource according to your requirements.
Run the command below to apply the DynaKube custom resource, making sure to replace
<your-DynaKube-CR>
with your actual DynaKube custom resource file name. A validation webhook will provide helpful error messages if there's a problem.kubectl apply -f <your-DynaKube-CR>.yaml
-
optional Verify deployment
Verify that your DynaKube is running and all pods in your Dynatrace namespace are running and ready.
> kubectl get dynakube -n dynatrace NAME APIURL STATUS AGE dynakube https://<ENVIRONMENTID>.live.dynatrace.com/api Running 45s
In a default DynaKube configuration with CSI driver, you should see the following pods:
> kubectl get pods -n dynatrace NAME READY STATUS RESTARTS AGE dynakube-activegate-0 1/1 Running 0 50s dynatrace-oneagent-csi-driver-qxfwx 4/4 Running 0 2m49s dynatrace-oneagent-csi-driver-xk5c4 4/4 Running 0 2m49s dynatrace-oneagent-csi-driver-mz6ch 4/4 Running 0 2m49s dynatrace-operator-7dc8dc7d8c-wmh4z 1/1 Running 0 2m59s dynatrace-webhook-7bb6957fb5-l8fsq 1/1 Running 0 2m59s dynatrace-webhook-7bb6957fb5-rqnqk 1/1 Running 0 2m59s
CSI driver is optional (see Step 2). If enabled, it gets deployed as DaemonSet and results in a CSI-driver pod on each node.
-
Add the Dynatrace Helm repository
helm repo add dynatrace \ https://raw.githubusercontent.com/Dynatrace/dynatrace-operator/main/config/helm/repos/stable
Note that attempting to access the above URL will result in a 404 error page as it is only used internally by the Helm client.
-
Install Dynatrace Operator
You have two options:
Option 1: Install Dynatrace Operator using the default values:
helm install dynatrace-operator dynatrace/dynatrace-operator \ --set "installCRD=true" \ --set "csidriver.enabled=true" \ --atomic \ --create-namespace --namespace dynatrace
Option 2: For additional configuration to the Helm chart, edit the
values.yaml
sample from GitHub, then run the install command passing the YAML file as an argument:helm install dynatrace-operator dynatrace/dynatrace-operator \ -f values.yaml \ --atomic \ --create-namespace --namespace dynatrace
If
installCRD
is set tofalse
, you need to create the custom resource definition manually before starting the Helm installation:oc apply -f https://github.com/Dynatrace/dynatrace-operator/releases/download/v0.13.0/dynatrace-operator-crd.yaml
-
Create secret for Access tokens
Create a secret named
dynakube
for the API token and data ingest token obtained in Tokens and permissions required.oc -n dynatrace create secret generic dynakube --from-literal="apiToken=<API_TOKEN>" --from-literal="dataIngestToken=<DATA_INGEST_TOKEN>"
-
Apply the DynaKube custom resource
Download the DynaKube custom resource sample for application monitoring from GitHub. In addition, you can review the available parameters or how-to-guides, and adapt the DynaKube custom resource according to your requirements.
Run the command below to apply the DynaKube custom resource, making sure to replace
<your-DynaKube-CR>
with your actual DynaKube custom resource file name. A validation webhook will provide helpful error messages if there's a problem.oc apply -f <your-DynaKube-CR>.yaml
-
optional Verify deployment
Verify that your DynaKube is running and all pods in your Dynatrace namespace are running and ready.
> oc get dynakube -n dynatrace NAME APIURL STATUS AGE dynakube https://<ENVIRONMENTID>.live.dynatrace.com/api Running 45s
In a default DynaKube configuration with CSI driver, you should see the following pods:
> oc get pods -n dynatrace NAME READY STATUS RESTARTS AGE dynakube-activegate-0 1/1 Running 0 50s dynatrace-oneagent-csi-driver-qxfwx 4/4 Running 0 2m49s dynatrace-oneagent-csi-driver-xk5c4 4/4 Running 0 2m49s dynatrace-oneagent-csi-driver-mz6ch 4/4 Running 0 2m49s dynatrace-operator-7dc8dc7d8c-wmh4z 1/1 Running 0 2m59s dynatrace-webhook-7bb6957fb5-l8fsq 1/1 Running 0 2m59s dynatrace-webhook-7bb6957fb5-rqnqk 1/1 Running 0 2m59s
CSI driver is optional (see Step 2). If enabled, it gets deployed as DaemonSet and results in a CSI-driver pod on each node.
Learn more
After you've successfully installed the Dynatrace Operator, you may find the following resources helpful for further learning and troubleshooting.
Get actionable answers
Start to analyze your Kubernetes clusters and containerized Apps with Dynatrace and benefit from actionable answers.
Guides
Learn how you can configure Dynatrace Operator to support specific use cases.
Troubleshooting
Troubleshoot any challenges you may encounter while working with the Dynatrace Operator and its various components.
How it works
Want to learn more about the Dynatrace components in your Kubernetes cluster?
Reference
API reference and configuration options for all Dynatrace components within your Kubernetes cluster.
Dynatrace Operator release notes
See release notes for Dynatrace Operator.
Update or uninstall
This page provides a detailed instructions on how to update and uninstall Dynatrace Operator.