Skip to content

Commit 10c878d

Browse files
bonnefoabitomaxsp
andauthored
Add new cgroup metrics metadata (DataDog#20564)
* Add new cgroup metrics metadata Follow up of DataDog/datadog-agent#37328 which adds additional memory metrics from cgroup. * Add docs about extended metrics * Improve public docs - add mentions of the flag they enabled with --------- Co-authored-by: Dmitry <dmitry.ponomarev@datadoghq.com>
1 parent 4653f69 commit 10c878d

2 files changed

Lines changed: 49 additions & 35 deletions

File tree

container/README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ The `container` check requires some folders to be mounted to allow for automatic
2020

2121
### Configuration
2222

23-
The `container` check does not expose any specific configuration settings. To customize common fields or to force the activation of the `container` check, follow these steps:
23+
The `container` check exposes specific configuration settings to emit extended memory metrics in addition to standard set. To customize common fields or to force the activation of the `container` check, follow these steps:
2424

2525
1. Create the `container.d/conf.yaml` file in the `conf.d/` folder at the root of your Agent's configuration directory.
2626

@@ -39,6 +39,8 @@ Some metrics may not be available depending on your environment (Linux / Windows
3939

4040
See [metadata.csv][3] for a list of metrics provided by this integration.
4141

42+
If you need extended container memory metrics `extended_memory_metrics` has to be set to `true`. It will enable following metrics: active_anon, inactive_anon, active_file, inactive_file, unevictable, shmem, file_mapped, file_dirty, file_writeback, page_tables, refault_anon, refault_file
43+
4244
## Troubleshooting
4345

4446
Need help? Contact [Datadog support][1].

container/metadata.csv

Lines changed: 46 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,46 @@
1-
metric_name,metric_type,interval,unit_name,per_unit_name,description,orientation,integration,short_name,curated_metric
2-
container.cpu.limit,gauge,,nanocore,,The maximum CPU time available to the container,0,container,cpu_limit,
3-
container.cpu.system,gauge,,nanocore,,The container system CPU usage,0,container,cpu_system,
4-
container.cpu.throttled,gauge,,nanosecond,,The total cpu throttled time,0,container,cpu_throttled,
5-
container.cpu.throttled.periods,gauge,,,,The number of periods during which the container was throttled,0,container,cpu_throttled_periods,
6-
container.cpu.usage,gauge,,nanocore,,The container total CPU Usage,0,container,cpu_total,
7-
container.cpu.user,gauge,,nanocore,,The container userspace CPU usage,0,container,cpu_user,
8-
container.io.read,gauge,,byte,,The number of bytes read from disks by this container,0,container,io_read,
9-
container.io.read.operations,gauge,,,,The number of read operations done by this container,0,container,io_read_ops,
10-
container.io.write,gauge,,byte,,The number of bytes written to disks by this container,0,container,io_write,
11-
container.io.write.operations,gauge,,,,The number of write operations done by this container,0,container,io_write_ops,
12-
container.memory.cache,gauge,,byte,,The container cache usage,0,container,mem_cache,
13-
container.memory.commit,gauge,,byte,,The container commit memory usage,0,container,mem_commit,
14-
container.memory.commit.peak,gauge,,byte,,The container peak commit memory usage,0,container,mem_commit_peak,
15-
container.memory.kernel,gauge,,byte,,The container kernel memory usage,0,container,mem_kernel_usage,
16-
container.memory.limit,gauge,,byte,,The container memory limit,0,container,mem_limit,
17-
container.memory.major_page_faults,count,,,,Number of major page faults incurred,0,container,pgmajfault,
18-
container.memory.oom_events,gauge,,,,The number of OOM events triggered by the container,0,container,mem_oom_events,
19-
container.memory.page_faults,count,,,,Total number of page faults incurred,0,container,pgfault,
20-
container.memory.rss,gauge,,byte,,The container RSS usage,0,container,mem_rss,
21-
container.memory.soft_limit,gauge,,byte,,The container memory soft limit,0,container,mem_soft_limit,
22-
container.memory.swap,gauge,,byte,,The container swap usage,0,container,mem_swap,
23-
container.memory.usage,gauge,,byte,,The container total memory usage,0,container,mem_usage,
24-
container.memory.usage.peak,gauge,,byte,,The maximum memory usage recorded since the container started,0,container,mem_usage_peak,
25-
container.memory.working_set,gauge,,byte,,The container working set usage,0,container,mem_workingset,
26-
container.net.rcvd,gauge,,byte,,The number of network bytes received (per interface),0,container,net_sent,
27-
container.net.rcvd.packets,gauge,,,,The number of network packets received (per interface),0,container,net_p_rcvd,
28-
container.net.sent,gauge,,byte,,The number of network bytes sent (per interface),0,container,net_sent,
29-
container.net.sent.packets,gauge,,,,The number of network packets sent (per interface),0,container,net_p_sent,
30-
container.pid.open_files,gauge,,,,The number of open file descriptors (Linux only),0,container,open_files,
31-
container.pid.thread_count,gauge,,,,The number of threads running inside this container,0,container,thread_count,
32-
container.pid.thread_limit,gauge,,,,The maximum number of threads for this container,0,container,thread_limit,
33-
container.restarts,gauge,,,,The number of container restarted,0,container,restarts,
34-
container.uptime,gauge,,second,,The container uptime,0,container,uptime,
1+
metric_name,metric_type,interval,unit_name,per_unit_name,description,orientation,integration,short_name,curated_metric,sample_tags
2+
container.cpu.limit,gauge,,nanocore,,The maximum CPU time available to the container,0,container,cpu_limit,,
3+
container.cpu.system,gauge,,nanocore,,The container system CPU usage,0,container,cpu_system,,
4+
container.cpu.throttled,gauge,,nanosecond,,The total cpu throttled time,0,container,cpu_throttled,,
5+
container.cpu.throttled.periods,gauge,,,,The number of periods during which the container was throttled,0,container,cpu_throttled_periods,,
6+
container.cpu.usage,gauge,,nanocore,,The container total CPU Usage,0,container,cpu_total,,
7+
container.cpu.user,gauge,,nanocore,,The container userspace CPU usage,0,container,cpu_user,,
8+
container.io.read,gauge,,byte,,The number of bytes read from disks by this container,0,container,io_read,,
9+
container.io.read.operations,gauge,,,,The number of read operations done by this container,0,container,io_read_ops,,
10+
container.io.write,gauge,,byte,,The number of bytes written to disks by this container,0,container,io_write,,
11+
container.io.write.operations,gauge,,,,The number of write operations done by this container,0,container,io_write_ops,,
12+
container.memory.active_anon,gauge,,byte,,The container active anonymous memory (requires extended_memory_metrics flag in the check config),0,container,mem_active_anon,,
13+
container.memory.active_file,gauge,,byte,,The container active file-backed memory (requires extended_memory_metrics flag in the check config),0,container,mem_active_file,,
14+
container.memory.cache,gauge,,byte,,The container cache usage,0,container,mem_cache,,
15+
container.memory.commit,gauge,,byte,,The container commit memory usage,0,container,mem_commit,,
16+
container.memory.commit.peak,gauge,,byte,,The container peak commit memory usage,0,container,mem_commit_peak,,
17+
container.memory.file_dirty,gauge,,byte,,The container memory that are waiting to get written back to the disk (requires extended_memory_metrics flag in the check config),0,container,mem_dirty,,
18+
container.memory.file_mapped,gauge,,byte,,The container mapped file memory (requires extended_memory_metrics flag in the check config),0,container,mem_file_mapped,,
19+
container.memory.file_writeback,gauge,,byte,,The container memory that is queued for syncing to disk (requires extended_memory_metrics flag in the check config),0,container,mem_writeback,,
20+
container.memory.inactive_anon,gauge,,byte,,The container inactive anonymous memory (requires extended_memory_metrics flag in the check config),0,container,mem_inactive_anon,,
21+
container.memory.inactive_file,gauge,,byte,,The container inactive file-backed memory (requires extended_memory_metrics flag in the check config),0,container,mem_inactive_file,,
22+
container.memory.kernel,gauge,,byte,,The container kernel memory usage,0,container,mem_kernel_usage,,
23+
container.memory.limit,gauge,,byte,,The container memory limit,0,container,mem_limit,,
24+
container.memory.major_page_faults,count,,,,Number of major page faults incurred,0,container,pgmajfault,,
25+
container.memory.oom_events,gauge,,,,The number of OOM events triggered by the container,0,container,mem_oom_events,,
26+
container.memory.page_faults,count,,,,Total number of page faults incurred,0,container,pgfault,,
27+
container.memory.page_tables,gauge,,byte,,The container memory allocated for page tables (requires extended_memory_metrics flag in the check config),0,container,mem_pagetables,,
28+
container.memory.refault_anon,count,,byte,,The number of refaults of previously evicted anonymous pages (requires extended_memory_metrics flag in the check config),-1,container,mem_refault_anon,,
29+
container.memory.refault_file,count,,byte,,The number of refaults of previously evicted file pages (requires extended_memory_metrics flag in the check config),-1,container,mem_refault_page,,
30+
container.memory.rss,gauge,,byte,,The container RSS usage,0,container,mem_rss,,
31+
container.memory.shmem,gauge,,byte,,"The container swap-backed memory such as tmpfs (requires extended_memory_metrics flag in the check config), shm segments...",0,container,mem_shmem,,
32+
container.memory.soft_limit,gauge,,byte,,The container memory soft limit,0,container,mem_soft_limit,,
33+
container.memory.swap,gauge,,byte,,The container swap usage,0,container,mem_swap,,
34+
container.memory.unevictable,gauge,,byte,,The container memory that can't be reclaimed (requires extended_memory_metrics flag in the check config),0,container,mem_unevictable,,
35+
container.memory.usage,gauge,,byte,,The container total memory usage,0,container,mem_usage,,
36+
container.memory.usage.peak,gauge,,byte,,The maximum memory usage recorded since the container started,0,container,mem_usage_peak,,
37+
container.memory.working_set,gauge,,byte,,The container working set usage,0,container,mem_workingset,,
38+
container.net.rcvd,gauge,,byte,,The number of network bytes received (per interface),0,container,net_sent,,
39+
container.net.rcvd.packets,gauge,,,,The number of network packets received (per interface),0,container,net_p_rcvd,,
40+
container.net.sent,gauge,,byte,,The number of network bytes sent (per interface),0,container,net_sent,,
41+
container.net.sent.packets,gauge,,,,The number of network packets sent (per interface),0,container,net_p_sent,,
42+
container.pid.open_files,gauge,,,,The number of open file descriptors (Linux only),0,container,open_files,,
43+
container.pid.thread_count,gauge,,,,The number of threads running inside this container,0,container,thread_count,,
44+
container.pid.thread_limit,gauge,,,,The maximum number of threads for this container,0,container,thread_limit,,
45+
container.restarts,gauge,,,,The number of container restarted,0,container,restarts,,
46+
container.uptime,gauge,,second,,The container uptime,0,container,uptime,,

0 commit comments

Comments
 (0)