AppDynamics Knowledge Base

How to collect the debug-level Cluster Agent logs

How to collect the debug-level Cluster Agent logs

Why do I need to collect the debug-level log file?

The Cluster Agent by default logs the entries at the info level. Sometimes, the debug-level log files are necessary to investigate an experienced issue. Debug-level logging logs are more insightful entries that can be later used to identify the root cause of the experienced issue. There are two ways you can collect the agent log files at the desired logging level.

  1. By editing the currently running Cluster Agent
  2. By updating the Cluster Agent with a new configuration.

1. Edit the currently running Cluster Agent

  1. Determine the clusteragent object name:
    kubectl -n appdynamics edit clusteragent -n appdynamics
    Lukasz_Kociuba_1-1768225331435.png
  2. Edit the YAML file as shown below to set the logLevel to DEBUG, then save it (similar to using the vi editor):
    kubectl edit clusteragent <cluster_agent_name> -n appdynamics
    Edit the file to include:
    Lukasz_Kociuba_0-1768225248065.png

    Save the configuration: `:wq`

  3. Delete Cluster Agent pod with old configuration:
    kubectl delete pod <cluster-agent-pod> -n appdynamics
  4. Now cluster should spin up a new cluster agent pod.
    Keep the cluster-agent running for 15 minutes in debug logging mode.
  5. Collect logs by executing:
    kubectl logs <cluster-agent-pod> -n appdynamics > cluster-agent.log
  6. Revert the changes

2. Update the Cluster Agent with a new configuration.

  1. Edit the configuration:
    a) Kubernetes CLI installation -> "cluster-agent.yaml" file
    Lukasz_Kociuba_0-1768226093201.png
    b) Helm Chart installation -> "values.yaml" file
    Lukasz_Kociuba_1-1768226340550.png
  2. Apply the changes
    a) Kubernetes CLI installation -> kubectl apply -f cluster-agent.yaml
    b) Helm Chart installation -> helm upgrade <release_name> -f values.yaml appdynamics-cloud-helmcharts/cluster-agent -n appdynamics
  3. Now cluster should spin up a new cluster agent pod.
    Keep the cluster-agent running for 15 minutes in debug logging mode.
  4. Collect logs by executing:
    kubectl logs <cluster-agent-pod> -n appdynamics > cluster-agent.log
  5. Revert the changes

 

I hope this article was helpful. Feel free to ask in case of any questions.

Labels (2)
Version history
Last update:
‎01-12-2026 11:16 AM
Updated by: