AppDynamics Knowledge Base

How to Enable Debug Mode for AppDynamics Controller Logs (Jetty-based)

How to Enable Debug Mode for AppDynamics Controller Logs (Jetty-based)

This guide explains how to enable debug-level logging in the Jetty-based AppDynamics Controller. This is especially helpful when troubleshooting issues across key components like Business Transactions, Metrics, Events, and more.

It is intended for system administrators managing self-hosted AppDynamics environments who need granular log details without restarting services.


Prerequisites

  • Admin or root access to the Controller host machine

  • Familiarity with XML configuration files

  • Basic understanding of Java logging levels (e.g., INFO, DEBUG, TRACE)


Step-by-Step Instructions

Step 1: Log in to the Controller Server

SSH into the host where the AppDynamics Controller is installed:

ssh user@<controller-host>

Step 2: Locate the logback.xml File

Navigate to the logging configuration file:

cd <controller_home>/appserver/jetty/resources/

The file you need to edit is:

logback.xml

🔎 This file controls logging levels for all Controller components using the Logback framework.


Step 3: Modify Log Level by Component

  1. Open the file in a text editor:

    vi logback.xml
  2. Find or add the logger entry for the desired component. For example, to enable DEBUG logs for Hibernate:

    <logger name="com.hibernate" level="DEBUG"/>
  3. To enable debug logging for a common Controller component (e.g., Business Transactions or Metrics), you might add:

    <logger name="com.singularity.BT" level="DEBUG"/>
    <logger name="com.singularity.metrics" level="DEBUG"/>
  4. Save and close the file.


Step 4: Wait for Changes to Take Effect

You do not need to restart the Controller. Log level changes made in logback.xml take effect within a few minutes automatically.


Troubleshooting

Logs Not Updating with New Verbosity

Solution:

  • Ensure your XML syntax is valid and enclosed within <configuration> tags

  • Double-check that the logger name is spelled correctly

  • Wait a few minutes—Logback applies changes dynamically

Excessive Log File Growth

Solution:

  • Return the level to INFO or WARN after troubleshooting

  • Enable log rotation via configuration or scheduled scripts


Additional Notes / Best Practices

  • Use targeted component loggers to avoid noise. Some common loggers include:

    • com.singularity.BT for Business Transactions

    • com.singularity.metrics for Metrics

    • com.singularity.snapshots for Snapshots

    • com.singularity.orchestration for Orchestration

  • Avoid leaving DEBUG or TRACE logging on for long periods in production environments


Conclusion

By editing the logback.xml file, you can enable debug logging in the Jetty-based AppDynamics Controller without restarting services. This allows you to collect detailed diagnostic data during issues while maintaining flexibility and control.


FAQ

Q: Do I need to restart the Controller after editing logback.xml?
A: No, changes are picked up automatically within a few minutes.

Q: Where are the debug logs stored?
A: Logs are written to the standard Controller log directory, typically:

<controller_home>/logs/server.log

Q: Can I enable debug mode for just one module?
A: Yes, by specifying the exact logger (e.g., com.singularity.metrics) in logback.xml.

Version history
Last update:
‎07-02-2025 12:40 PM
Updated by:
Contributors