[Nagiosplug-help] check_http returns WARNING status on errors
Andreas Ericsson
ae at op5.se
Mon Nov 21 08:52:01 CET 2005
David G. Schlecht wrote:
> Hi All,
>
> Looking at the code for check_http (~line 986) v1.4.2 /* client
> errors result in a warning state */ else if (http_status >= 400) die
> (STATE_WARNING, _("HTTP WARNING: %s\n"), status_line
>
> A WARNING state on 404 errors seems, well, wrong. In my feeble way of
> thinking, any result that doesn't have the expected string should be
> a CRITICAL status.
>
So what would be a warning state? Getting a return code at all means
that the server responds (i.e. isn't down or overloaded enough for us to
time out), but the response prevents us from getting a proper metric.
> How do you experts handle this? I've considered sending notifications
> on WARNING state but the status of 'WARNING' is going to convey that
> it's not a critical error so it will, at times, get overlooked.
>
HTTP is tricky because it has a long list of error codes. Some will
always think that some error codes means something else for their
server. The best one can do is to add some sort of user-definable table
to be specified on the command line. No-one has felt it needed enough to
add one yet though.
--
Andreas Ericsson andreas.ericsson at op5.se
OP5 AB www.op5.se
Tel: +46 8-230225 Fax: +46 8-230231
More information about the Help
mailing list