Thursday, May 23rd 2013, 2:13am UTC+2
You are not logged in.
Dear visitor, welcome to Monitoring-Portal.
Although this is a german monitoring forum, please don't hesitate to post in
English. Nearly everybody here understands you and will answer in English as well.
If this is your first visit here, please read the Help. It explains how this page works. You must be registered before you can use all the page's features. Please use the registration form to register here or read more information about the registration process. If you are already registered, please login here.
Beginner
Number of monitoring servers: 1
Nagios Version: 3
Distributed monitoring: Nein
Redundant monitoring: Nein
Number of hosts: 1200+
Number of services: 4000+
OS: RHEL 5.8
Plugin Version: 1.4.15
NDO Version: 1
|
|
Source code |
1 2 3 4 5 |
command[ DB_LogGenCheckpointDepth ] = check_nrpe -H $HOSTADDRESS$ -p 5666 -c CheckCounter -a "Counter=\\MSExchange Database ==> Instances(*)\\Log Generation Checkpoint Depth" ShowAll MaxWarn=30 MaxCrit=40 command[ DB_PageFaultsStalls ] = check_nrpe -H $HOSTADDRESS$ -p 5666 -c CheckCounter -a "Counter=\\MSExchange Database(Information Store)\\Database Page Fault Stalls/sec" ShowAll MaxWarn=5 MaxCrit=10 command[ DB_LogRecordsStalls ] = check_nrpe -H $HOSTADDRESS$ -p 5666 -c CheckCounter -a "Counter=\\MSExchange Database(Information Store)\\Log Record Stalls/sec" ShowAll MaxWarn=10 MaxCrit=100 |
|
|
Source code |
1 2 3 4 5 6 7 8 9 |
#!/usr/bin/perl my $i = qx(./check_nrpe -H xxx.xxx.xxx.xxx -p 5666 -c CheckCounter -a "Counter=\\MSExchange Database ==> Instances(*)\\Log Generation Checkpoint Depth" ShowAll MaxWarn=30 MaxCrit=40); $i =~ s/==\>/--/g; $i =~ tr/\/\#()*/./; print $i; |
|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 |
command [ DB_LogGenCheckpointDepth ] = check_nrpe -H $HOSTADDRESS$ -p 5666 -c CheckCounter -a "Counter=\\MSExchange Database ==> Instances(*)\\Log Generation Checkpoint Depth" ShowAll MaxWarn=30 MaxCrit=40 eeval [ clean_out ] = \ $DB_LogGenCheckpointDepth$ =~ s/==\>/--/g; \ $DB_LogGenCheckpointDepth$ =~ tr/\/\#()*/./; \ return $DB_LogGenCheckpointDepth$; |
Location: Esslingen
Number of monitoring servers:
Nagios Version:
Distributed monitoring: Nein
Redundant monitoring: Nein
Number of hosts:
Number of services:
OS:
Plugin Version:
NagVis Version:
NDO Version:
Perfparse Version:
Other Addons:
command [ DB_LogGenCheckpointDepth ] = check_nrpe -H $HOSTADDRESS$ -p 5666 -c CheckCounter -a "Counter=\\MSExchange Database ==> Instances(*)\\Log Generation Checkpoint Depth" ShowAll MaxWarn=30 MaxCrit=40
eeval [ clean_out ] = \
$DB_LogGenCheckpointDepth$ =~ s/==\>/--/g; \
$DB_LogGenCheckpointDepth$ =~ tr/\/\#()*/./; \
return $DB_LogGenCheckpointDepth$;
Quoted
command [ DB_LogGenCheckpointDepth ] = check_nrpe ...
output [ DB_LogGenCheckpointDepth ] = "", my $s="$DB_LogGenCheckpointDepth$"; $s=~s/==>/--/g; $s=~ tr/\/\#\(\)\*/./; printf "\n%s", $s;
Beginner
Number of monitoring servers: 1
Nagios Version: 3
Distributed monitoring: Nein
Redundant monitoring: Nein
Number of hosts: 1200+
Number of services: 4000+
OS: RHEL 5.8
Plugin Version: 1.4.15
NDO Version: 1
|
|
Source code |
1 2 3 4 5 |
(No output returned from plugin) CRITICAL: MSExchange Database -- Instances(*)og generation checkpoint depth: 67 > criticalcheck_multi CRITICAL - 1 plugins checked, 2 critical (DB_LogGenCheckpointDepth, DB_LogGenCheckpointDepth) [Unrecognized escape \M passed through at (eval 17) line 1. generated at line 3413 in /usr/local/nagios/libexec/check_multi ((eval))] |
This post has been edited 2 times, last edit by "HiPHil" (May 23rd 2012, 1:42pm)
Number of monitoring servers: 2-5
Nagios Version: 3.x
Distributed monitoring: Nein
Redundant monitoring: Nein
Number of hosts: 80-200
Number of services: 1400-2000
OS: Linux
Plugin Version: Whatever I can download, patch, or cobble together myself :-)
Other Addons: n2rrd, PNP, livestatus
Wenn Du das meinen solltest, "No output returned from ..." bügelt Nagios selbst drüber, wenn das Plugin (Trommelwirbel!) keinen (Text-)Output zurückgegeben hat.Woher kommt überhaupt das output-Keyword? Finde das in keiner Doku.
|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 |
# grep -n 'plugin_output=[^=].*"' ~/nagios-3.2.3/base/checks.c
1003: temp_service->plugin_output=(char *)strdup("(Service check did not exit properly)");
1028: temp_service->plugin_output=(char *)strdup("(No output returned from plugin)");
2740: hst->plugin_output=(char *)strdup("(Host assumed to be UP)");
2747: hst->plugin_output=(char *)strdup("(No output returned from host check)");
3318: temp_host->plugin_output=(char *)strdup("(No output returned from host check)");
3348: temp_host->plugin_output=(char *)strdup("(Host check did not exit properly)");
3370: temp_host->plugin_output=(char *)strdup("(Host assumed to be UP)");
# grep -n '>plugin_output,.*[^"]"[^"]' ~/nagios-3.2.3/base/checks.c
1015: asprintf(&temp_service->plugin_output,"(Return code of %d is out of bounds%s)",queued_check_result->return_code,(queued_check_result->return_code==126 ? " - plugin may not be executable" : (queued_check_result->return_code==127 ?" - plugin may be missing":"")));
3362: asprintf(&temp_host->plugin_output,"(Return code of %d is out of bounds%s)",queued_check_result->return_code,(queued_check_result->return_code==126 || queued_check_result->return_code==127)?" - plugin may be missing":"");
|
Beginner
Number of monitoring servers: 1
Nagios Version: 3
Distributed monitoring: Nein
Redundant monitoring: Nein
Number of hosts: 1200+
Number of services: 4000+
OS: RHEL 5.8
Plugin Version: 1.4.15
NDO Version: 1
|
|
Source code |
1 2 3 |
[root@grzslx007 ~]# cat /usr/local/nagios/etc/check_multi/check_multi_db_test.cmd command [ DB_LogGenCheckpointDepth ] = check_nrpe -H $HOSTADDRESS$ -p 5666 -c CheckCounter -a "Counter=\\MSExchange Database ==> Instances(*)\\Log Generation Checkpoint Depth" ShowAll MaxWarn=30 MaxCrit=40 output [ DB_LogGenCheckpointDepth ] = "", my $s="$DB_LogGenCheckpointDepth$"; $s=~s/\=\=/--/g; $s=~s/\(\*\)/xxx/g; printf "\n%s", $s; |
|
|
Source code |
1 2 |
CRITICAL: MSExchange Database --> Instancesxxxog generation checkpoint depth: 66 > criticalcheck_multi CRITICAL - 1 plugins checked, 2 critical (DB_LogGenCheckpointDepth, DB_LogGenCheckpointDepth) [please don't run plugins as root!,Unrecognized escape \M passed through at (eval 17) line 1. generated at line 3413 in /usr/local/nagios/libexec/check_multi ((eval))] <div><table style='border-left-width:1px; border-right-width:0px; border-left-style:dotted' id=multi_table><tr style='font-size:8pt'><td nowrap><table style='background-color:#F83838'><tr style='vertical-align:middle'><td style='font-size:6pt'> 1</td></tr></table></td><td nowrap><A TARGET='_self' HREF='/pnp4nagios/graph?host=GRZSMS580&srv=DB_LogGenCheckpointDepth'> <img src='/nagios/images/action.gif' width=20 height=20 border=0 align=top alt='Show performance chart for GRZSMS580 / check_nrpe'></A></td><td></td><td>DB_LogGenCheckpointDepth</td><td>1</td></tr></table></div>|check_multi::check_multi::plugins=1 time=1.434218 'DB_LogGenCheckpointDepth::check_nrpe::\MSExchange Database ==> Instances(*)\Log Generation Checkpoint Depth'=66;30;40 |
Beginner
Number of monitoring servers: 1
Nagios Version: 3
Distributed monitoring: Nein
Redundant monitoring: Nein
Number of hosts: 1200+
Number of services: 4000+
OS: RHEL 5.8
Plugin Version: 1.4.15
NDO Version: 1
|
|
Source code |
1 2 3 4 5 |
Status Information: (No output returned from plugin) CRITICAL: MSExchange Database --> Instancesxxxog generation checkpoint depth: 67 > criticalcheck_multi CRITICAL - 1 plugins checked, 2 critical (DB_LogGenCheckpointDepth, DB_LogGenCheckpointDepth) [Unrecognized escape \M passed through at (eval 17) line 1. generated at line 3413 in /usr/local/nagios/libexec/check_multi ((eval))] 1 DB_LogGenCheckpointDepth 1 Performance Data: check_multi::check_multi::plugins=1 time=1.383206 'DB_LogGenCheckpointDepth::check_nrpe::\MSExchange Database ==> Instances(*)\Log Generation Checkpoint Depth'=67;30;40 |
Beginner
Number of monitoring servers: 1
Nagios Version: 3
Distributed monitoring: Nein
Redundant monitoring: Nein
Number of hosts: 1200+
Number of services: 4000+
OS: RHEL 5.8
Plugin Version: 1.4.15
NDO Version: 1
|
|
Source code |
1 2 |
[root@grzslx007 libexec]# ./check_nrpe_db_perf.sh -H grzsms580 -p 5666 -c CheckCounter -a "Counter=\\9144(*)\\3298" index ShowAll MaxWarn=30 MaxCrit=40 CRITICAL: \MSExchange Database Instances\Log Generation Checkpoint Depth: 43 > critical|'\MSExchange Database Instances\Log Generation Checkpoint Depth'=43;30;40 |
|
|
Source code |
1 |
2012-06-21 10:40:50 [7741] [1] Found Performance Data for GRZSMS580 / Exchange2010_DB_Perf_TEST2 (\MSExchange Database Instances\Log Generation Checkpoint Depth=45;30;40) |
Beginner
Number of monitoring servers: 1
Nagios Version: 3
Distributed monitoring: Nein
Redundant monitoring: Nein
Number of hosts: 1200+
Number of services: 4000+
OS: RHEL 5.8
Plugin Version: 1.4.15
NDO Version: 1
|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 |
#!/bin/bash LINE=`/usr/local/nagios/libexec/check_nrpe $*` RC=$? LINE=`echo $LINE | sed 's/==>//g'` LINE=`echo $LINE | sed 's/*//g'` LINE=`echo $LINE | sed 's/(//g'` LINE=`echo $LINE | sed 's/)//g'` echo $LINE exit $RC |
|
|
Source code |
1 |
check_nrpe_db_perf.sh -H grzsms580 -p 5666 -c CheckCounter -a "Counter=\\9144(*)\\3298" index ShowAll MaxWarn=30 MaxCrit=40 |
|
|
Source code |
1 2 3 |
[root@grzslx007 libexec]# ./check_nrpe_db_perf.sh -H grzsms580 -p 5666 -c CheckCounter -a "Counter=\\MSExchange Database ==> Instances(*)\\Log Generation Checkpoint Depth" ShowAll MaxWarn=30 MaxCrit=40 CRIT: Counter not found: \MSExchange: Unable to parse the counter path. Check the format and syntax of the specified path. (C0000BC0) |
Number of monitoring servers: 2-5
Nagios Version: 3.x
Distributed monitoring: Nein
Redundant monitoring: Nein
Number of hosts: 80-200
Number of services: 1400-2000
OS: Linux
Plugin Version: Whatever I can download, patch, or cobble together myself :-)
Other Addons: n2rrd, PNP, livestatus
Ja, für solche Zwecke gibt's neben "$*" noch das "$@":kann mir jemand sagen, was ich tun muss, damit das wrapper-script das richtig weitergibt?
|
|
Source code |
1 2 3 4 5 6 7 8 |
[root@nagios AMC]# ~/JoB/TMP.sh AMC_Load.rrd "AMC_CPU Usage.rrd" AMC_PING.rrd -rw-r--r-- 1 nagios nagios 552412 21. Jun 22:12 AMC_CPU Usage.rrd -rw-r--r-- 1 nagios nagios 185116 21. Jun 22:15 AMC_Load.rrd -rw-rw-r-- 1 nagios apache 246328 21. Jun 22:16 AMC_PING.rrd [root@nagios AMC]# cat ~/JoB/TMP.sh #!/bin/sh OUTPUT=`ls -l "$@"` echo "$OUTPUT" |