Docker instrumentation for Infrastructure

The New Relic Infrastructure agent automatically monitors your Docker containers. With Docker monitoring you can:

  • Group containers by tags, attributes, and other metadata.
  • Search for containers relevant to your monitoring scenario.
  • Link to related entities that may be affected by issues with the container.
  • Set Docker-related alert conditions.

You can alternatively use a Docker image containing the Infrastructure agent, see Infrastructure CoreOS Docker container.

Requirements

Requirement details for automatic Docker container monitoring for the New Relic Infrastructure agent:

  • Infrastructure Pro subscription or trial
  • Infrastructure agent 1.8.32 or higher running on Linux
  • If using CentOS: must have CentOS version 6.0 or higher
  • Docker version 1.12 or higher

Enable Docker container monitoring

If you meet the requirements and have installed the correct Infrastructure agent, there are no additional steps to enable Docker monitoring. If Docker is running, data will automatically be reported.

Alternatively, you can use a Docker image that contains the Infrastructure agent, see Infrastructure CoreOS Docker container.

Find your Docker data

You can view your Docker data in the Infrastructure UI in either of these ways:

To see more detailed charts, click Dashboards.

View container data in New Relic Infrastructure
infrastructure.newrelic.com> Hosts > Containers: View data related to your Docker containers, and understand how that performance impacts your overall environment. To see more detailed charts, select Dashboard.

Docker attributes

Docker attributes (metrics and metadata) are attached to the ContainerSample event. Here's an example of a query to find out how many containers are associated with each Docker image:

SELECT uniqueCount(containerId) FROM ContainerSample FACET imageName SINCE 1 HOUR AGO TIMESERIES

For information on how to explore and query data, see Query your data.

To see all ContainerSample attributes, see our data dictionary. Attributes include:

  • General metadata (like containerId, name, and image)
  • CPU metrics (like cpuUsedCores, cpuPercent, and cpuThrottleTimeMs)
  • Memory metrics (like memoryUsageBytes, memoryCacheBytes, and memoryResidentSizeBytes)
  • Network metrics (like networkRxBytes, networkRxDropped, and networkTxBytes)

The reported data does not include information related to the container orchestrator (for example, ECS or Kubernetes). To monitor those, you can add the orchestrator's cluster and task names as labels.

Docker metrics are also attached to the ProcessSample event.

Set alert conditions

To create Docker-related alert conditions:

For more help

Recommendations for learning more: