check_http and *.jsp
Patrick LeBoutillier
patrick_leboutillier at hotmail.com
Mon Jun 16 16:23:52 CEST 2003
Here's my stab at it:
It's probably a HTTP/1.0 vs. HTTP/1.1 issue.
HTTP/1.1 requires a specific header (Host: ) to be sent by the client in
order for the
HTTP request to be valid.
The plugin code does this:
case 'H': /* Host Name (virtual host) */
asprintf (&host_name, "%s", optarg);
break;
then this:
/* optionally send the host header info (not clear if it's usable) */
if (strcmp (host_name, ""))
asprintf (&buf, "%sHost: %s\r\n", buf, host_name);
So if you don't use the -H option, you can't succesfully talk to a HTTP/1.1
server.
---------------------
Patrick LeBoutillier
Laval, Quebec, Canada
----- Original Message -----
From: "Andrzej Wisniewski" <andrzej.wisniewski at contium.pl>
To: "Karl DeBisschop" <karl at debisschop.net>
Cc: "Nagios Users" <nagios-users at lists.sourceforge.net>
Sent: Monday, June 16, 2003 7:33 AM
Subject: Re: [Nagios-users] check_http and *.jsp
> > > # ./check_http www.someserver.com -u /somefile.jsp
> > > HTTP ok: HTTP/1.1 200 ok - 5 second response time
> > >
> > > but I have not source of this plugin :(
> > > Well, I have this problem with all JSP files :(
> > > Can somebody help me ?
> >
> > Have you tried the full POSIX-style invocation?
> >
> > ./check_http -I www.someserver.com -H www.someserver.com \
> > -u /somefile.jsp
>
> Wow ! :)
> With this style everything is ok. I don't know why but fact is the fact :)
> Tx
>
> --
> AndY
>
>
>
> -------------------------------------------------------
> This SF.NET email is sponsored by: eBay
> Great deals on office technology -- on eBay now! Click here:
> http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
> _______________________________________________
> 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
>
-------------------------------------------------------
This SF.NET email is sponsored by: eBay
Great deals on office technology -- on eBay now! Click here:
http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
_______________________________________________
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