monitoring website

Justin Pasher justinp at newmediagateway.com
Mon Mar 9 21:03:06 CET 2009


Harry John wrote:
> Hi friends,
>  
> am just wondering how  to monitor a  website as
> http://172.168.1.1:82/xap/murl2?language=en
>  
> define service{
> use generic-service ; Inherit default values from a template
> host_name remotehost
> service_description HTTP
> check_command check_http
> }
> How do I fit this link here?

You'll need to call the check_http script with the -u option. The 
default "check_http" command doesn't do this, so you'll have to create a 
new one. Since you're also querying a custom port, you'll need to pass 
that info along too. Something like this is one way to do it:


define command {
    command_name    check_http_path
    command_line    /usr/lib/nagios/plugins/check_http -H '$ARG1$' -u 
'$ARG2$' -w $ARG3$ -c $ARG4$
}

define service {
    use generic-service ; Inherit default values from a template
    host_name remotehost
    service_description HTTP
    check_command check_http_path!172.168.1.1:82 
<http://172.168.1.1:82/xap/murl2?language=en>!/xap/murl2?language=en 
<http://172.168.1.1:82/xap/murl2?language=en>!25!50
}


-- 
Justin Pasher

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list