Imported Upstream version 0.6.24+dfsg1
This commit is contained in:
30
share/pnp/documents/de_DE/wrapper.html
Normal file
30
share/pnp/documents/de_DE/wrapper.html
Normal file
@@ -0,0 +1,30 @@
|
||||
|
||||
<p>
|
||||
check_procs ist ein Beispiel für ein Plugin, das keine Performance-Daten ausgibt:
|
||||
</p>
|
||||
<pre class="code">./check_procs -a ndo2db -w 1: -c 0:
|
||||
PROCS OK: 2 processes with args 'ndo2db'</pre>
|
||||
|
||||
<p>
|
||||
Mit dem folgenden Wrapper-Script kann das geändert werden
|
||||
</p>
|
||||
|
||||
<p>
|
||||
<strong>check_procs.sh</strong>
|
||||
|
||||
</p>
|
||||
<pre class="code">#!/bin/bash
|
||||
LINE=`/usr/local/nagios/libexec/check_procs $*`
|
||||
RC=$?
|
||||
COUNT=`echo $LINE | awk '{print $3}'`
|
||||
PROCS=`expr $COUNT - 1`
|
||||
LINE=`echo $LINE | sed "s/: $COUNT /: $PROCS /"`
|
||||
echo $LINE \| procs=$PROCS
|
||||
exit $RC</pre>
|
||||
|
||||
<p>
|
||||
Nun wird die Zahl zusammen mit einer Bezeichnung ausgegeben.
|
||||
|
||||
</p>
|
||||
<pre class="code">./check_procs.sh -a ndo2db -w 1: -c 0:
|
||||
PROCS OK: 2 processes with args 'ndo2db'| procs=2</pre>
|
||||
Reference in New Issue
Block a user