[Nagiosplug-help] check_http problem

Alex Griffin agriffin at nagios.com
Thu Aug 18 16:45:27 CEST 2011


Can you post your command definition? In the mean time, when you test 
plugins from the command line, make sure you run them as the nagios 
user. In this case I doubt it would make a difference unless your 
machine is really locked down, but sometimes it makes a very big difference.

Alex Griffin
---
Tech Team
agriffin at nagios.com

On 08/18/2011 06:18 AM, Chris Datfung wrote:
> I've searched the archives and seen several similar scenarios but none
> of the solutions I saw worked for me. I have several identical
> configurations (sans the IP address, domain name etc) that use
> check_http to monitor several web servers. When I manually check via the
> CLI, I get a 200 response for all of them, but when Nagios checks it
> returns a 200 for some, while others get either the following error
> message:
> CRITICAL - Socket timeout after 10 seconds
>
> or a 401 or 403 response. As I mentioned, if I copy and paste the
> check_http command via the CLI they all return a 200 response. The only
> difference I can tell is the check_http checks that don't work have a a
> different IP specified to use via the -I flag then what was in the
> address field of the host definition. FWIW, I've checked with check_http
> v1.4.14 and v1.4.15 with identical results. The following is an example
> configuration that returns the socket timeout error when run by Nagios:
>
> define host{
> use generic-host
> host_name server-prod
> alias  Prod Web Server
> address  xxx.xxx.xxx.101
> hostgroups http-servers,ssh-servers
> check_command check_ssh
> }
>
> define service {
> use generic-service
> host_name server-prod
> service_description server-domainname.com <http://server-domainname.com>
> check_command check_http!-I xxx.xxx.xxx.102 -H domainname.com
> <http://domainname.com> -t 60 -S
> }
>
> Why does this check work via the CLI and fail when Nagios runs it? How
> can I add debugging that shows up in the logs for this specific check?
>
> Thanks,
> Chris
>
>
>
> ------------------------------------------------------------------------------
> Get a FREE DOWNLOAD! and learn more about uberSVN rich system,
> user administration capabilities and model configuration. Take
> the hassle out of deploying and managing Subversion and the
> tools developers use with it. http://p.sf.net/sfu/wandisco-d2d-2
>
>
>
> _______________________________________________
> Nagiosplug-help mailing list
> Nagiosplug-help at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/nagiosplug-help
> ::: Please include plugins version (-v) and OS when reporting any issue.
> ::: Messages without supporting info will risk being sent to /dev/null




More information about the Help mailing list