Check_http returns 400 Bad request

Toto Capuccino shoktai at gmail.com
Fri Jan 20 09:17:51 CET 2006


Thanks! I got it working now.


2006/1/19, Hugo van der Kooij <hvdkooij at vanderkooij.org>:
>
> On Thu, 19 Jan 2006, Toto Capuccino wrote:
>
> > I try to check that our Outlook Web Access server is up and running so i
> > defined my commands check_http like this:
> > # 'check_http' command definition
> > define command{
> >         command_name    check_http
> >         command_line    $USER1$/check_http -H $HOSTNAME$ -u $ARG1$
> >         }
> > and services this way :
> > check_command      check_http!rcorpsv04!http://www.rmkmail.com
> >
> > i get in return [1137662549] SERVICE ALERT:
> > rcorpsv04;HTTP;WARNING;HARD;3;HTTP WARNING: HTTP/1.1 400 Bad Request
> >
> > It looks like it's missing a host header field, how can i solve this ?
>
> You use an incorrect URL. The manual said:
> -u, --url=PATH
>    URL to GET or POST (default: /)
>
> What is more I am puzzled why it did not complain about the fact that you
> send 2 variables and handle only the first.
>
> It should be more like:
>
> define command{
>         command_name    check_http_url
>         command_line    $USER1$/check_http -H $ARG1$ -u $ARG2$
>         }
>
> check_http_url!aragorn!/icons/powered_by_fedora.png
>
> This will resul in 'aragorn' being used for the host header
>
> Hugo.
>
> --
>         I hate duplicates. Just reply to the relevant mailinglist.
>         hvdkooij at vanderkooij.org                http://hvdkooij.xs4all.nl/
>                 Don't meddle in the affairs of magicians,
>                 for they are subtle and quick to anger.
>
>
> -------------------------------------------------------
> This SF.net email is sponsored by: Splunk Inc. Do you grep through log
> files
> for problems?  Stop!  Download the new AJAX search engine that makes
> searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
> _______________________________________________
> 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
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-lists.org/archive/users/attachments/20060120/1afbc521/attachment.html>


More information about the Users mailing list