Skip to content

Commit 0cb56bb

Browse files
authored
docs: in_process_exporter_metrics: fix defaults, sort tables, add metric details (#2328)
1 parent 7bc94c7 commit 0cb56bb

File tree

1 file changed

+41
-9
lines changed

1 file changed

+41
-9
lines changed

pipeline/inputs/process-exporter-metrics.md

Lines changed: 41 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -20,25 +20,57 @@ All metrics including those collected with this plugin flow through a separate p
2020

2121
| Key | Description | Default |
2222
|---------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------|
23-
| `scrape_interval` | The rate, in seconds, at which metrics are collected. | `5` |
24-
| `path.procfs` | The mount point used to collect process information and metrics. Read-only permissions are enough. | `/proc/` |
25-
| `process_include_pattern` | Regular expression to determine which names of processes are included in the metrics produced by this plugin. It's applied for all process unless explicitly set. | `.+` |
23+
| `metrics` | Specify which process level of metrics are collected from the host operating system. Actual values of metrics will be read from `/proc` when needed. `context_switches`, `cpu`, `fd`, `io`, `memory`, `start_time`, `state`, `thread`, and `thread_wchan` metrics depend on `procfs`. | `cpu,io,memory,state,context_switches,fd,start_time,thread_wchan,thread` |
24+
| `path.procfs` | The mount point used to collect process information and metrics. Read-only permissions are enough. | `/proc` |
2625
| `process_exclude_pattern` | Regular expression to determine which names of processes are excluded in the metrics produced by this plugin. It's not applied unless explicitly set. | `NULL` |
27-
| `metrics` | Specify which process level of metrics are collected from the host operating system. Actual values of metrics will be read from `/proc` when needed. `cpu`, `io`, `memory`, `state`, `context_switches`, `fd,` `start_time`, `thread_wchan`, and `thread` metrics depend on `procfs`. | `cpu,io,memory,state,context_switches,fd,start_time,thread_wchan,thread` |
26+
| `process_include_pattern` | Regular expression to determine which names of processes are included in the metrics produced by this plugin. It's applied for all process unless explicitly set. | `.+` |
27+
| `scrape_interval` | The rate, in seconds, at which metrics are collected. | `5` |
2828

29-
## Available metrics
29+
## Available metrics
3030

3131
| Name | Description |
3232
|--------------------|-----------------------------------------------------|
33+
| `context_switches` | Exposes `context_switches` statistics from `/proc`. |
3334
| `cpu` | Exposes CPU statistics from `/proc`. |
35+
| `fd` | Exposes file descriptors statistics from `/proc`. |
3436
| `io` | Exposes I/O statistics from `/proc`. |
3537
| `memory` | Exposes memory statistics from `/proc`. |
36-
| `state` | Exposes process state statistics from `/proc`. |
37-
| `context_switches` | Exposes `context_switches` statistics from `/proc`. |
38-
| `fd` | Exposes file descriptors statistics from `/proc`. |
3938
| `start_time` | Exposes `start_time` statistics from `/proc`. |
40-
| `thread_wchan` | Exposes `thread_wchan` from `/proc`. |
39+
| `state` | Exposes process state statistics from `/proc`. |
4140
| `thread` | Exposes thread statistics from `/proc`. |
41+
| `thread_wchan` | Exposes `thread_wchan` from `/proc`. |
42+
43+
### Prometheus metric names
44+
45+
The following tables describe the Prometheus metrics exposed by each collector.
46+
47+
#### Process-level metrics
48+
49+
| Prometheus Metric | Enabled by | Type | Description |
50+
|-------------------------------------|-------------------|---------|----------------------------------------------------|
51+
| `process_context_switches_total` | `context_switches`| counter | Context switches (voluntary and non-voluntary). |
52+
| `process_cpu_seconds_total` | `cpu` | counter | CPU usage in seconds (user and system). |
53+
| `process_fd_ratio` | `fd` | gauge | Ratio between open file descriptors and max limit. |
54+
| `process_major_page_faults_total` | `memory` | counter | Major page faults. |
55+
| `process_memory_bytes` | `memory` | gauge | Memory in use (virtual memory and `RSS`). |
56+
| `process_minor_page_faults_total` | `memory` | counter | Minor page faults. |
57+
| `process_num_threads` | `thread` | gauge | Number of threads. |
58+
| `process_open_filedesc` | `fd` | gauge | Number of open file descriptors. |
59+
| `process_read_bytes_total` | `io` | counter | Number of bytes read. |
60+
| `process_start_time_seconds` | `start_time` | gauge | Start time in seconds since 1970/01/01. |
61+
| `process_states` | `state` | gauge | Process state (R, S, D, Z, T, or I). |
62+
| `process_write_bytes_total` | `io` | counter | Number of bytes written. |
63+
64+
#### Thread-level metrics
65+
66+
| Prometheus Metric | Enabled by | Type | Description |
67+
|--------------------------------------------|----------------|---------|---------------------------------------------------------|
68+
| `process_thread_context_switches_total` | `thread` | counter | Thread context switches (voluntary and non-voluntary). |
69+
| `process_thread_cpu_seconds_total` | `thread` | counter | Thread CPU usage in seconds (user and system). |
70+
| `process_thread_io_bytes_total` | `thread` | counter | Thread I/O bytes (read and write). |
71+
| `process_thread_major_page_faults_total` | `thread` | counter | Thread major page faults. |
72+
| `process_thread_minor_page_faults_total` | `thread` | counter | Thread minor page faults. |
73+
| `process_thread_wchan` | `thread_wchan` | gauge | Number of threads waiting on each `wchan`. |
4274

4375
## Threading
4476

0 commit comments

Comments
 (0)