Build precise queries to find exactly what you need
Press ESC to close
Join our next live webinar: “Advanced Nagios Monitoring Techniques” – Register Now
Your review has been submitted and is pending approval.
sh compliant script to check CPU utilization via /proc/stat instead of top or iostat (PNP template included)
Current Version
Last Release Date
June 8, 2009
Owner
Nagios Exchange
Website
http://www.matejunkie.com/
Compatible With
PNP Template
The script (Version 1.0)
The appropriate license
Description check_cpu.sh is a Nagios plugin to monitor CPU utilization. It makes use of /proc/stat and calculates it through Jiffies rather than using another frontend tool like iostat or top. When using optional warning/critical thresholds all values except idle are aggregated and compared to the thresholds. There's currently no support for warning/critical thresholds for specific usage parameters. Version Version 1.0, 2009, Mike Adolphs (http://www.matejunkie.com/) -h/--help Output check_cpu.sh [-i/--interval] [-w/--warning] [-c/--critical] Options: --interval|-i) Defines the pause between the two times /proc/stat is being parsed. Higher values could lead to more accurate result. Default is: 1 second --warning|-w) Sets a warning level for CPU user. Default is: off --critical|-c) Sets a critical level for CPU user. Default is: off Output example user@host:~$ ./check_cpu.sh OK - user: 8.42, nice: 0.50, sys: 6.66, iowait: 0.50, irq: 0.50, softirq: 0.50 idle: 86.40 | 'user'=8.42 'nice'=0.50 'sys'=6.66 'softirq'=0.50 'iowait'=0.50 'irq'=0.50 'idle'=86.40 Changelog * 2009-05-14 o Small bugfix of an exit code
I don't see any options for monitoring a remote host. Is this possible?
This plugins is good but has a small mistake in the PNP4Nagios template. The iowait is 4th value in chech_cpu.php and the 5th value in the perfdata output. But overall a usefull plugin with nice template.
./check_cpu_se.sh gives output on redhat but error on command line 118 and several others on gentoo, works through nrpe and draws graphs on pnp4nagios
You must be logged in to submit a review.
To:
From: