[Nagiosplug-help] check_bl issue

Scott Lambert lambert at lambertfam.org
Mon Jul 10 20:22:57 CEST 2006


On Sat, Jul 08, 2006 at 04:05:27AM +0200, Guilherme Alberto wrote:
> Hello,
> 
> I have a working nagios with lots of plugins currently working,
>  although I am getting wierd errors with the last installed plugins:
> 
> - check_bl (Plugin that check if IP is listed in spam blacklists)
> 
> Nagios shows:
> (No output!) (This is being shown on localhost running nagios and
>  in any other IP I try to check)
> 
> checkcommands.cfg:
> 
> define command{ 
> command_name check_bl
> 
> command_line $USER1$/check_bl -H $HOSTADDRESS$ -B sbl-xbl.spamhaus.org,bl
> .spamcop.net,t1.dnsbl.net.au
> 
> }
> 
> 
> When I run it through shell it works smoothly:
> 
> root at gui [/usr/local/nagios/libexec]# ./check_bl -H 66.98.166.XXX
>  -B sbl-xbl.spamhaus.org,bl.spamcop.net,t1.dnsbl.net.au 
> 
> Not black-listed

try this:

root at gui [/usr/local/nagios/libexec]# cd
root at gui [~/]# /usr/local/nagios/libexec/check_bl -H 66.98.166.XXX \
> -B sbl-xbl.spamhaus.org,bl.spamcop.net,t1.dnsbl.net.au

My bet is that you will need to modify a path in check_bl to point to
the $USER1$ directory.  When I installed it on FreeBSD, the path to
the plugins directory where the util script is was hardcoded to what I
presume is the default Linux location for the plugins.  I think "." is
in the search path for loading the utils file.  That would explain why
it works from the plugin directory on the command line.


-- 
Scott Lambert                    KC5MLE                       Unix SysAdmin
lambert at lambertfam.org





More information about the Help mailing list