Showing results for 
Show  only  | Search instead for 
Did you mean: 

Monitor a specific namespace in GKE Environment.


OneAgent monitors all the namespace including Dynatrace namespace where OneAgent is installed.

1). We are getting unwanted logs of oneAgent and other namespace containers and pods.
2). We are unwanted monitoring the namespace and containers , pods , infrasture details etc.

How to restrict oneAgent to monitored a specific namespace in dynakube.YAML


Dynatrace Guru
Dynatrace Guru

By default, Dynatrace Operator injects OneAgent into all namespaces, with the following exceptions:

  • Namespaces starting with kube-or openshift-.
  • The namespace where Dynatrace Operator was installed.

There are more configuration options:

  1. Monitor all namespaces except selected pods.
  2. Monitor only specific namespaces.
    • If you don't want Dynatrace Operator to inject OneAgent in all namespaces, you can set the namespaceSelector the parameter in the DynaKube custom resource, and enable monitoring for specific namespaces that have the chosen label.
  3. Exclude specific namespaces from being monitored.
    • To enable this option, edit the DynaKube custom resource file.

Read more at:

Senior Product Manager,
Dynatrace Managed expert


command exexuted : kubectl label namespace wa monitor=app


Dynakube YAML :

monitor: app


But still the other namespace and other container logs are shown inside the kubernetes page.

Hi Radoslaw

Does this also work for Classic full-stack installation?

Featured Posts