Nagios plugins: check_http
Posted: Tue Oct 28, 2014 1:36 pm
I have a problem with plugin check_http, when i run manually
/usr/lib/nagios/plugins$ ./check_http -H server.com -u /bla/bla/bla.jsp -s "wordtosearch"
HTTP OK: HTTP/1.1 200 OK - 26784 bytes en 0,561 segundo tiempo de respuesta |time=0,561292s;;;0,000000 size=26784B;;;0
but when i define as service:
define service {
use generic-service
host_name server.com
service_description server.com
check_command check_http! -H server.com -u /bla/bla/bla.jsp -s "wordtosearch" (or check_http! -u /bla/bla/bla.jsp -s "wordtosearch")
}
the result is:
HTTP WARNING: HTTP/1.1 404 Not Found
/usr/lib/nagios/plugins$ ./check_http -H server.com -u /bla/bla/bla.jsp -s "wordtosearch"
HTTP OK: HTTP/1.1 200 OK - 26784 bytes en 0,561 segundo tiempo de respuesta |time=0,561292s;;;0,000000 size=26784B;;;0
but when i define as service:
define service {
use generic-service
host_name server.com
service_description server.com
check_command check_http! -H server.com -u /bla/bla/bla.jsp -s "wordtosearch" (or check_http! -u /bla/bla/bla.jsp -s "wordtosearch")
}
the result is:
HTTP WARNING: HTTP/1.1 404 Not Found