Using double slashes ?
Danny Wigmans
danny.wigmans at solcorp.com
Tue Nov 11 23:25:57 CET 2003
Hi Garry,
I just saw that there was a -I in the cfg file (Left over from one of the
tests). However, it does not matter whether I use -H or -I. I played with
those args as well....working in the shell, not working in the script.
Thanks for the reply though !
Danny
-----Original Message-----
From: Cook, Garry [mailto:GWCOOK at mactec.com]
Sent: Tuesday, November 11, 2003 23:28
To: Danny Wigmans
Subject: RE: [Nagios-users] Using double slashes ?
Is the '-I' in your command line below a type-o, or is that how it really
appears in the config file? I believe that should be '-H' before the host
address.
Garry W. Cook, CCNA
Network Infrastructure Manager
MACTEC, Inc. - http://www.mactec.com/ <http://www.mactec.com/>
303.308.6228 (Office) - 720.220.1862 (Mobile)
-----Original Message-----
From: Danny Wigmans [mailto:danny.wigmans at solcorp.com]
Sent: Tuesday, November 11, 2003 2:17 PM
To: 'nagios-users at lists.sourceforge.net'
Subject: [Nagios-users] Using double slashes ?
Hi,
I am trying to get the check_http plug-in to work, so I can check a proxy
server.
The command I try to use is:
./check_http -H $HOSTADDRESS$ -u http://www.yahoo.com <http://www.yahoo.com>
-e HTTP/1.1 200
Though the command works fine from the bash shell on RH 9 under the nagios
user account, it doesn't work through the scripts...
When executing from the shell I get a HTTP Ok response, from the scripts it
returns a HTTP CRITICAL.
I am using nagios-1.1 and nagios-plugins-1.3.1 (check_http (1.24.2.4) from
SourceForge...
My hunch is that the // in the URL are not taken literal but are being
interpreted by nagios. Anyone any ideas, or a possible workaround? I have
already tried using \ as escape char, using %47%47, creating a macro in
resources.cfg, double quoting the URL, and passing it from services to a
$ARG1$ macro in my check_command, and combinations of these. Nothing worked
so far..
Ideas anyone???
Thanks,
Danny
My files look as follows:
checkcommands.cfg:
define command{
command_name check_http_proxy
command_line $USER1$/check_http -I $HOSTADDRESS$ -u
http://www.yahoo.com <http://www.yahoo.com> -e HTTP/1.1 200
}
services.cfg:
define service {
name generic-service-template
active_checks_enabled 1
passive_checks_enabled 1
parallelize_check 1
obsess_over_service 1
check_freshness 0
notifications_enabled 1
event_handler_enabled 1
flap_detection_enabled 1
process_perf_data 1
retain_status_information 1
retain_nonstatus_information 1
max_check_attempts 3
normal_check_interval 5
retry_check_interval 2
check_period 24x7
notification_interval 240
notification_period 24x7
notification_options w,c
register 0
}
define service {
name http-proxy-template
service_description HTTP Proxy
check_command check_http_proxy
use generic-service-template
register 0
}
define service {
hostgroup_name proxy-srv
contact_groups admin-group
use http-proxy-template
}
_____
This e-mail message has been scanned for Viruses and Content and cleared.
_____
_____
This e-mail message has been scanned for Viruses and Content and cleared.
_____
##############################################################
This e-mail message has been scanned for Viruses and Contents
##############################################################
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-lists.org/archive/users/attachments/20031111/dbd13b7b/attachment.html>
More information about the Users
mailing list