(New in 4.3.3) You can use the Standalone Machine Agent to monitor application nodes running inside Docker containers and to identify container issues that impact application performance. By viewing and comparing APM metrics with the underlying container and server/machine metrics, you can easily answer the question: Is my application problem purely an application problem, or is the root cause in the container or the server?
Docker Container monitoring requires a Server Visibility license and version 4.3.3 or higher of both the Controller and the Standalone Machine Agent.
The Standalone Machine Agent should be deployed inside a Docker container. The Standalone Machine Agent can then collect metrics for other containers on the same host, in addition to server and machine metrics for the host itself. The Controller then shows all monitored containers (for each host) and the container and host IDs (for each container).
The following diagram illustrates the deployment scenario for container monitoring:
- Install one Standalone Machine Agent ( ) in a standalone container.
- Install an APM Agent (
Each app agent needs to run with system properties as described in Before Starting below. ) inside each container you want to monitor.
The Standalone Machine Agent then collects hardware metrics for each monitored container, as well as Machine and Server metrics for the host (), and forwards the metrics to the Controller.
Note the following:
- AppDynamics recommends that you use Docker CE/EE v17.03 or Docker Engine v1.13 with this product. Some data might be missing if you are using previous versions of Docker.
- Docker Visibility is not supported on Docker for Windows or Docker for Mac.
- AppDynamics strongly recommends that you run each app agent with node reuse enabled. (If you cannot enable node reuse in your environment, a possible workaround is to mark nodes as historical using the API after they are shut down. Node reuse is the recommended method, however.)
To enable node reuse, enable the Reuse Node Name and specify the Reuse Node Name Prefix as described in Java Agent Configuration Properties:
- (New in 4.3.7) The Machine Agent can monitor up to 120 running containers per host and does not prioritize. (The default maximum is 15. See Configuring Docker Visibility.) The Standalone Machine Agent collects metrics from containers with one or more running processes whose command line matches a configurable regex. By default, this regex matches processes that are are running with the
-Dappdynamicsprefix option. If you cannot restart the APM agents, or if you to want to filter APM agents based on another command-line argument, you can override this behavior. Edit the following regex in
containerMonitoringConfig:containerProcessSelectorRegex: ".*[ ]-Dappdynamics.*"
- The maximum number of containers you can monitor in one Controller depends on the Controller size, the total number of App Agents, and the current load. If you are using a SaaS Controller, please work with your Account Manager.
- Please review the Docker Visibility Known Issues in the 4.3.3 Release Notes.
Docker Visibility Setup
Do the following:
- Update the Controller to 4.3.3 or higher if you have not already done so.
- Create a folder on the host (<
machine_agent_home>) where you want to install the machine agent.
- Go to the AppDynamics Download Center and download the Standalone Machine Agent installer (version 4.3.3 or higher).
- Build a Docker container to run the Standalone Machine Agent with Docker Visibility enabled.
Viewing Container Metrics
To view container metrics in the Controller:
- Go to Servers > Containers to see a list of the monitored containers deployed on the same host.
- To view metrics for a specific container, right-click on the container name and choose View Details.
- Go to the Node Dashboard for the underlying server and then go to the Container tab.
Watch the Video
For full-screen viewing, click Integrated Container (Docker) Visibility.