Hi

I´m using nagios version 2.10 and trying to determine de disponibility of my 
website using check_http to find a string in a url.
If i execute this command in the prompt:
         /usr/local/nagios/libexec/check_http -H www.mywebsite.com.br -u 
/internet/principal.jsp -s "String to find"
i get:
        HTTP OK HTTP/1.1 200 OK - 1.805 second response time 
|time=1.804832s;;;0.000000 size=20593B;;;0

and if i change the string i get:
        HTTP CRITICAL - string not found|time=1.835345s;;;0.000000 
size=20593B;;;0


So I put in the service.cfg:

define service{
    use website-service
    host_name internet
    service_description HTTP
    check_command check_http!-u /internet/principal.jsp -s "String to find"
}

and I have in the nagios page the service status, having the string in the page 
or not:

    Status Information:HTTP OK HTTP/1.1 200 OK - 369 bytes in 0.005 seconds 
    Performance Data:time=0.005401s;;;0.000000 size=369B;;;0

In the command.cfg I have:
define command{
    command_name check_http
    command_line $USER1$/check_http -H $HOSTADDRESS$
}

Someone can help me?

Leandro
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Nagios-users mailing list
[email protected]
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

Reply via email to