---
title: Docker container metrics reference
source: https://docs.newrelic.com/docs/opentelemetry/integrations/docker-monitoring/metrics-reference
---

This page provides a comprehensive reference for all Docker container metrics collected by the OpenTelemetry [dockerstatsreceiver](https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/receiver/dockerstatsreceiver). Use this reference to understand what data is available, create custom queries, and set up effective alerts for your containerized applications.

## Complete metrics reference [#metrics-reference]

The OpenTelemetry Collector Contrib's [dockerstatsreceiver](https://github.com/open-telemetry/opentelemetry-collector-contrib/tree/main/receiver/dockerstatsreceiver) collects the following metrics from the Docker Stats API:

**Metrics**

| Metric                                            | Description                                                                                                                                | Type  |
| ------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------ | ----- |
| `container.blockio.io_merged_recursive`           | Number of bios/requests merged into requests belonging to this cgroup and its descendant cgroups                                           | Sum   |
| `container.blockio.io_queued_recursive`           | Number of requests queued up for this cgroup and its descendant cgroups                                                                    | Sum   |
| `container.blockio.io_service_bytes_recursive`    | Number of bytes transferred to/from the disk by the group and descendant groups                                                            | Sum   |
| `container.blockio.io_service_time_recursive`     | Total amount of time in nanoseconds between request dispatch and request completion for the IOs done by this cgroup and descendant cgroups | Sum   |
| `container.blockio.io_serviced_recursive`         | Number of IOs (bio) issued to the disk by the group and descendant groups                                                                  | Sum   |
| `container.blockio.io_time_recursive`             | Disk time allocated to cgroup (and descendant cgroups) per device in milliseconds                                                          | Sum   |
| `container.blockio.io_wait_time_recursive`        | Total amount of time the IOs for this cgroup (and descendant cgroups) spent waiting in the scheduler queues for service                    | Sum   |
| `container.cpu.usage.kernelmode`                  | CPU kernel mode usage                                                                                                                      | Sum   |
| `container.cpu.usage.percpu`                      | Per-core CPU usage by the container (disabled by default)                                                                                  | Sum   |
| `container.cpu.usage.system`                      | System CPU usage                                                                                                                           | Sum   |
| `container.cpu.usage.total`                       | Total CPU time consumed by the container                                                                                                   | Sum   |
| `container.cpu.usage.usermode`                    | CPU user mode usage                                                                                                                        | Sum   |
| `container.cpu.percent`                           | Percent of CPU used by the container (deprecated, use container.cpu.utilization instead)                                                   | Gauge |
| `container.cpu.utilization`                       | Percent of CPU used by the container                                                                                                       | Gauge |
| `container.cpu.throttling_data.periods`           | Number of periods with throttling active                                                                                                   | Sum   |
| `container.cpu.throttling_data.throttled_periods` | Number of periods when the container hit its throttling limit                                                                              | Sum   |
| `container.cpu.throttling_data.throttled_time`    | Aggregate time the container was throttled                                                                                                 | Sum   |
| `container.cpu.limit`                             | CPU limit set for the container                                                                                                            | Gauge |
| `container.cpu.logical.count`                     | Number of cores available to the container                                                                                                 | Gauge |
| `container.cpu.shares`                            | CPU shares allocated to the container                                                                                                      | Gauge |
| `container.cpu.cores.used`                        | Number of CPU cores used by the container                                                                                                  | Sum   |
| `container.memory.usage.limit`                    | Memory usage limit                                                                                                                         | Sum   |
| `container.memory.usage.max`                      | Maximum memory usage                                                                                                                       | Sum   |
| `container.memory.usage.total`                    | Memory usage of the container. This excludes the cache                                                                                     | Sum   |
| `container.memory.percent`                        | Percentage of memory used                                                                                                                  | Gauge |
| `container.memory.active_anon`                    | Amount of memory used in anonymous mappings such as brk(), sbrk(), and mmap(MAP_ANONYMOUS) that are actively used                          | Sum   |
| `container.memory.active_file`                    | Amount of cache memory used by files that are actively used                                                                                | Sum   |
| `container.memory.anon`                           | Amount of memory used in anonymous mappings (pages not backed by files)                                                                    | Sum   |
| `container.memory.cache`                          | The amount of memory used by the processes of this control group that can be associated with a block on a block device                     | Sum   |
| `container.memory.dirty`                          | Bytes that are waiting to get written back to the disk, from this cgroup                                                                   | Sum   |
| `container.memory.fails`                          | Number of times memory limit was hit                                                                                                       | Sum   |
| `container.memory.file`                           | Amount of memory used by files (file cache)                                                                                                | Sum   |
| `container.memory.hierarchical_memory_limit`      | The max amount of physical memory that the cgroup can use                                                                                  | Sum   |
| `container.memory.hierarchical_memsw_limit`       | The max amount of RAM + swap that the cgroup can use                                                                                       | Sum   |
| `container.memory.inactive_anon`                  | Amount of memory used in anonymous mappings such as brk(), sbrk(), and mmap(MAP_ANONYMOUS) that are not actively used                      | Sum   |
| `container.memory.inactive_file`                  | Amount of cache memory used by files that are not actively used                                                                            | Sum   |
| `container.memory.mapped_file`                    | Indicates the amount of memory mapped by the processes in the control group                                                                | Sum   |
| `container.memory.pgfault`                        | Indicate the number of times that a process of the cgroup triggered a page fault                                                           | Sum   |
| `container.memory.pgmajfault`                     | Indicate the number of times that a process of the cgroup triggered a major fault                                                          | Sum   |
| `container.memory.pgpgin`                         | Number of pages read from disk by the cgroup                                                                                               | Sum   |
| `container.memory.pgpgout`                        | Number of pages written to disk by the cgroup                                                                                              | Sum   |
| `container.memory.rss`                            | The amount of memory that doesn't correspond to anything on disk: stacks, heaps, and anonymous memory maps                                 | Sum   |
| `container.memory.rss_huge`                       | Number of bytes of anonymous transparent hugepages in this cgroup                                                                          | Sum   |
| `container.memory.unevictable`                    | The amount of memory that cannot be reclaimed                                                                                              | Sum   |
| `container.memory.writeback`                      | Number of bytes of file/anon cache that are queued for syncing to disk in this cgroup                                                      | Sum   |
| `container.network.io.usage.rx_bytes`             | Bytes received by the container via its network interface                                                                                  | Sum   |
| `container.network.io.usage.rx_dropped`           | Number of received packets dropped by the container                                                                                        | Sum   |
| `container.network.io.usage.rx_errors`            | Received errors by the container                                                                                                           | Sum   |
| `container.network.io.usage.rx_packets`           | Packets received by the container via its network interface                                                                                | Sum   |
| `container.network.io.usage.tx_bytes`             | Bytes sent by the container via its network interface                                                                                      | Sum   |
| `container.network.io.usage.tx_dropped`           | Number of sent packets dropped by the container                                                                                            | Sum   |
| `container.network.io.usage.tx_errors`            | Transmission errors by the container                                                                                                       | Sum   |
| `container.network.io.usage.tx_packets`           | Packets sent by the container via its network interface                                                                                    | Sum   |
| `container.pids.count`                            | Number of PIDs in the container's cgroup                                                                                                   | Sum   |
| `container.pids.limit`                            | Maximum number of PIDs in the container's cgroup                                                                                           | Sum   |
| `container.restarts`                              | Number of times the container has been restarted                                                                                           | Sum   |
| `container.uptime`                                | Time elapsed since container started                                                                                                       | Gauge |

**Attributes**

| Attribute                  | Description                                                                     | Values                                                                                   |
| -------------------------- | ------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- |
| `collector.name`           | Custom attribute for collector identification (if configured in your collector) | String                                                                                   |
| `container.hostname`       | The hostname of the container                                                   | String                                                                                   |
| `container.id`             | The full container ID                                                           | String (64-character hex)                                                                |
| `container.image.name`     | Name of the container image                                                     | String                                                                                   |
| `container.name`           | Container name                                                                  | String                                                                                   |
| `container.runtime`        | Container runtime                                                               | `docker`                                                                                 |
| `deployment.environment`   | Deployment environment identifier (if configured in your collector)             | String                                                                                   |
| `description`              | Description of the metric                                                       | String                                                                                   |
| `device_major`             | Device major number (for block I/O metrics)                                     | Integer                                                                                  |
| `device_minor`             | Device minor number (for block I/O metrics)                                     | Integer                                                                                  |
| `entity.guid`              | New Relic entity GUID for the container                                         | String                                                                                   |
| `entity.name`              | New Relic entity name (typically the container name)                            | String                                                                                   |
| `entity.type`              | New Relic entity type                                                           | `CONTAINER`                                                                              |
| `instrumentation.provider` | Instrumentation provider identifier                                             | `opentelemetry`                                                                          |
| `interface`                | Network interface name (for network metrics)                                    | String                                                                                   |
| `newrelic.source`          | Source of the metric in New Relic                                               | `api.metrics.otlp`                                                                       |
| `nr.entity_type`           | New Relic entity type for entity correlation                                    | `CONTAINER`                                                                              |
| `operation`                | Type of block I/O operation                                                     | `read`, `write`                                                                          |
| `otel.library.name`        | OpenTelemetry library/receiver name                                             | `github.com/open-telemetry/opentelemetry-collector-contrib/receiver/dockerstatsreceiver` |
| `otel.library.version`     | OpenTelemetry library version                                                   | String (e.g., `0.142.0`)                                                                 |
| `service.name`             | Service name configured in the collector                                        | String                                                                                   |
| `telemetry.sdk.name`       | Telemetry SDK identifier                                                        | `opentelemetry`                                                                          |
| `unit`                     | Unit of measurement for the metric                                              | String (e.g., `{cpus}`, `By`, `1`)                                                       |

For more details, see the [Docker Stats receiver documentation](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/main/receiver/dockerstatsreceiver/documentation.md)

## Next steps [#next-steps]

Now that you understand Docker metrics:

-   [Set up monitoring](https://docs.newrelic.com/docs/opentelemetry/integrations/docker-monitoring/self-hosted) - Configure Docker monitoring if you haven't already
-   **Create dashboards**: Build [custom visualizations](https://docs.newrelic.com/docs/query-your-data/explore-query-data/dashboards/introduction-dashboards/) using the metrics in this reference
