Docker CLI
docker stats
Reports container resource observations. By default the display updates; --no-stream requests one sample. CPU, memory and I/O figures depend on the workload and platform, and a sample alone cannot identify the cause of a problem. The PIDS count on Linux includes threads. Example requires the approved bm-v04-debug fixture. A single observation does not identify a bottleneck or establish a benchmark.
Formal Syntax & Structure
docker syntaxdocker
docker stats [OPTIONS] [CONTAINER...]Parameters & Attributes
| Name | Type | Description |
|---|---|---|
| CONTAINER | string[] | Container names or IDs; scope requests to your lab. |
| --no-stream | flag | Return a single resource observation. |
| --format | string | Select output formatting; verify supported values. |
Working Example
Example Snippetdocker
docker stats --no-stream bm-v04-debug