check_http confusion / problem
jmoseley at corp.xanadoo.com
jmoseley at corp.xanadoo.com
Fri Aug 28 23:34:36 CEST 2009
Not sure if regular expressions will work, but here's an example:
[root at plugins]# ./check_http -H www -e "HTT"
HTTP OK HTTP/1.1 200 OK - 318 bytes in 0.004 seconds
|time=0.004054s;;;0.000000 size=318B;;;0
It finds the 'HTT' in the following status line:
STATUS: HTTP/1.1 200 OK
so it returns an 'OK' condition.
However:
[root at plugins]# ./check_http -H www -e "HTP"
HTTP CRITICAL - Invalid HTTP response received from host
There is no 'HTP' string in the status line, so the plugin returns a
critical condition.
James Moseley
"David Dyer-Bennet" <dd-b at dd-b.net> wrote:
That's where I found --expect= in the first place. All my tests showed it
not working as I "expected", and I started thrashing around as usual, and
eventually ended up with -e= which is of course wrong (incomplete
editing).
What is the argument? A regexp? The other match parameters are, but this
one doesn't say so. A full-line match? An initial segment match? Will
it match anywhere within the line?
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now. http://p.sf.net/sfu/bobj-july
_______________________________________________
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