[Nagiosplug-devel] ENC: Patches: check_swap and check_procs
Paulo Afonso Graner Fessel
paulo.fessel at primesys.com.br
Fri Jan 21 05:59:54 CET 2005
Paulo Afonso Graner Fessel
Administrador de Ambiente e Sistemas UNIX
paulo.fessel at primesys.com.br
OWT
Fone: +55 (11) 3038-6554
Fax: +55 (11) 3038-6508
http://www.primesys.com.br <http://www.primesys.com.br/>
________________________________
De: Paulo Afonso Graner Fessel
Enviada em: quinta-feira, 20 de janeiro de 2005 15:50
Para: 'nagiosplug-devel at lists.sourceforge.net'
Assunto: Patches: check_swap and check_procs
Hello, folks:
I have two patches here: the first for check_swap fixes the
problems found with AIX when using unsigned long long with gcc. Tested
in AIX 4.3 and 5.1 and linux 2.4 and 2.6.
The second is a patch that implements performance counters for
check_procs. When run without metrics specified, it can check against
warning and critical thresholds of the absolute number of processes.
When the option "--metric=VARIABLE" is specified, it will tell 3
counters: the number of process for which the counter is in "OK",
"WARNING" and "CRITICAL" states. Again, tested on linux and AIX.
Finally, someone who knows automake and autoconf (I don't)
should correct the ps command for procps-3.1(.19). By default it runs ps
as "ps -axwo" which causes check_procs to return with a warning:
[root at nagios plugins]# ./check_procs -vv
CMD: /bin/ps -axwo 'stat uid ppid vsz rss pcpu comm args'
STDERR: Warning: bad syntax, perhaps a bogus '-'? See
http://procps.sf.net/faq.html <http://procps.sf.net/faq.html>
System call sent warnings to stderr
PROCS WARNING: 285 processes | Processes=285;;;
After changing the ps command in config.h:
[root at nagios plugins]# ./check_procs -vv
CMD: /bin/ps axwo 'stat uid ppid vsz rss pcpu comm args'
PROCS OK: 271 processes | Processes=271;;;
Please evaluate the patches in other platforms and apply if
shouldn't bring problems.
[]'s
Paulo
Paulo Afonso Graner Fessel
Administrador de Ambiente e Sistemas UNIX
paulo.fessel at primesys.com.br
OWT
Fone: +55 (11) 3038-6554
Fax: +55 (11) 3038-6508
http://www.primesys.com.br <http://www.primesys.com.br/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-plugins.org/archive/devel/attachments/20050121/b58f6bc8/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: LogoPrimesys.gif
Type: image/gif
Size: 2173 bytes
Desc: LogoPrimesys.gif
URL: <https://www.monitoring-plugins.org/archive/devel/attachments/20050121/b58f6bc8/attachment.gif>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: LogoPrimesys.gif
Type: image/gif
Size: 2173 bytes
Desc: LogoPrimesys.gif
URL: <https://www.monitoring-plugins.org/archive/devel/attachments/20050121/b58f6bc8/attachment-0001.gif>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: check_procs_perfdata.diff
Type: application/octet-stream
Size: 1539 bytes
Desc: check_procs_perfdata.diff
URL: <https://www.monitoring-plugins.org/archive/devel/attachments/20050121/b58f6bc8/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: check_swap_aix_fix.diff
Type: application/octet-stream
Size: 10864 bytes
Desc: check_swap_aix_fix.diff
URL: <https://www.monitoring-plugins.org/archive/devel/attachments/20050121/b58f6bc8/attachment-0001.obj>
More information about the Devel
mailing list