Skip to content

Commit 9636c10

Browse files
committed
refactor(cpu-usage): improve comment
1 parent 7f6a8e0 commit 9636c10

File tree

3 files changed

+15
-13
lines changed

3 files changed

+15
-13
lines changed

check-plugins/cpu-usage/README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,8 @@ focusing on sustained load. Perfdata is emitted for every field to enable full
4444
graphing. Extended stats (context switches, interrupts, etc.) are included if
4545
supported on this platform. With `--top`, the most CPU-intensive processes are
4646
also listed for quick diagnosis. This check is cross-platform and works on
47-
Linux, Windows, and all psutil-supported systems.
47+
Linux, Windows, and all psutil-supported systems. The check stores its short
48+
trend state locally in an SQLite DB to evaluate sustained load across runs.
4849
4950
options:
5051
-h, --help show this help message and exit

check-plugins/cpu-usage/cpu-usage

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -33,19 +33,20 @@ __author__ = 'Linuxfabrik GmbH, Zurich/Switzerland'
3333
__version__ = '2025090701'
3434

3535
DESCRIPTION = """Reports CPU utilization percentages for all available time categories
36-
(user, system, idle, nice, iowait, irq, softirq, steal, guest, guest_nice) plus
37-
the overall cpu-usage (100 − idle − nice).
36+
(user, system, idle, nice, iowait, irq, softirq, steal, guest, guest_nice) plus the overall
37+
cpu-usage (100 − idle − nice).
3838
39-
Thresholds (WARN/CRIT) are checked against user, system, iowait, and cpu-usage.
40-
An alert is raised only if the threshold is exceeded for COUNT consecutive runs,
41-
suppressing short spikes and focusing on sustained load.
39+
Thresholds (WARN/CRIT) are checked against user, system, iowait, and cpu-usage. An alert is raised
40+
only if the threshold is exceeded for COUNT consecutive runs, suppressing short spikes and focusing
41+
on sustained load.
4242
43-
Perfdata is emitted for every field to enable full graphing. Extended stats
44-
(context switches, interrupts, etc.) are included if supported on this platform.
45-
With `--top`, the most CPU-intensive processes are also listed for quick diagnosis.
43+
Perfdata is emitted for every field to enable full graphing. Extended stats (context switches,
44+
interrupts, etc.) are included if supported on this platform. With `--top`, the most CPU-intensive
45+
processes are also listed for quick diagnosis.
4646
47-
This check is cross-platform and works on Linux, Windows, and all psutil-supported
48-
systems."""
47+
This check is cross-platform and works on Linux, Windows, and all psutil-supported systems.
48+
The check stores its short trend state locally in an SQLite DB to evaluate sustained load across
49+
runs."""
4950

5051

5152
DEFAULT_COUNT = 5 # measurements; if check runs once per minute, this is a 5 minute interval

check-plugins/cpu-usage/icingaweb2-module-director/cpu-usage.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@
162162
"tpl-service-generic"
163163
],
164164
"max_check_attempts": 5,
165-
"notes": "Reports CPU utilization percentages for all available time categories (user, system, idle, nice, iowait, irq, softirq, steal, guest, guest_nice) plus the overall cpu-usage (100 \u2212 idle \u2212 nice). Thresholds (WARN/CRIT) are checked against user, system, iowait, and cpu-usage. An alert is raised only if the threshold is exceeded for COUNT consecutive runs, suppressing short spikes and focusing on sustained load. Perfdata is emitted for every field to enable full graphing. Extended stats (context switches, interrupts, etc.) are included if supported on this platform. With `--top`, the most CPU-intensive processes are also listed for quick diagnosis. This check is cross-platform and works on Linux, Windows, and all psutil-supported systems.",
165+
"notes": "Reports CPU utilization percentages for all available time categories (user, system, idle, nice, iowait, irq, softirq, steal, guest, guest_nice) plus the overall cpu-usage (100 \u2212 idle \u2212 nice). Thresholds (WARN/CRIT) are checked against user, system, iowait, and cpu-usage. An alert is raised only if the threshold is exceeded for COUNT consecutive runs, suppressing short spikes and focusing on sustained load. Perfdata is emitted for every field to enable full graphing. Extended stats (context switches, interrupts, etc.) are included if supported on this platform. With `--top`, the most CPU-intensive processes are also listed for quick diagnosis. This check is cross-platform and works on Linux, Windows, and all psutil-supported systems. The check stores its short trend state locally in an SQLite DB to evaluate sustained load across runs.",
166166
"notes_url": "https://github.com/Linuxfabrik/monitoring-plugins/tree/main/check-plugins/cpu-usage",
167167
"object_name": "tpl-service-cpu-usage",
168168
"object_type": "template",
@@ -212,7 +212,7 @@
212212
"tpl-service-generic"
213213
],
214214
"max_check_attempts": 5,
215-
"notes": "Reports CPU utilization percentages for all available time categories (user, system, idle, nice, iowait, irq, softirq, steal, guest, guest_nice) plus the overall cpu-usage (100 \u2212 idle \u2212 nice). Thresholds (WARN/CRIT) are checked against user, system, iowait, and cpu-usage. An alert is raised only if the threshold is exceeded for COUNT consecutive runs, suppressing short spikes and focusing on sustained load. Perfdata is emitted for every field to enable full graphing. Extended stats (context switches, interrupts, etc.) are included if supported on this platform. With `--top`, the most CPU-intensive processes are also listed for quick diagnosis. This check is cross-platform and works on Linux, Windows, and all psutil-supported systems.",
215+
"notes": "Reports CPU utilization percentages for all available time categories (user, system, idle, nice, iowait, irq, softirq, steal, guest, guest_nice) plus the overall cpu-usage (100 \u2212 idle \u2212 nice). Thresholds (WARN/CRIT) are checked against user, system, iowait, and cpu-usage. An alert is raised only if the threshold is exceeded for COUNT consecutive runs, suppressing short spikes and focusing on sustained load. Perfdata is emitted for every field to enable full graphing. Extended stats (context switches, interrupts, etc.) are included if supported on this platform. With `--top`, the most CPU-intensive processes are also listed for quick diagnosis. This check is cross-platform and works on Linux, Windows, and all psutil-supported systems. The check stores its short trend state locally in an SQLite DB to evaluate sustained load across runs.",
216216
"notes_url": "https://github.com/Linuxfabrik/monitoring-plugins/tree/main/check-plugins/cpu-usage",
217217
"object_name": "tpl-service-cpu-usage-windows",
218218
"object_type": "template",

0 commit comments

Comments
 (0)