Check https but not http

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
theillien
Posts: 4
Joined: Tue Sep 06, 2011 4:00 pm

Check https but not http

Post by theillien »

I've disabled http on our Nagios server so the only way to access the interface is via https. I've used the instructions found online (http://communitygrids.blogspot.com/2010 ... oring.html) to create a check for https. The service shows up under the host, but it indicates a warning because of the 403 Forbidden code returned due to shutting down http.

I'm certain it is failing on http and not https due to the status message: HTTP WARNING: HTTP/1.1 403 Forbidden - 4183 bytes in 0.009 second response time

I don't even have http defined as a service in the localhost.cfg file anymore since moving it to https.

How can I disable checks on http and only check https?
theillien
Posts: 4
Joined: Tue Sep 06, 2011 4:00 pm

Re: Check https but not http

Post by theillien »

The entry in command.cfg:

Code: Select all

# 'check_https' command definition
define command{
        command_name    check_https
        command_line      $USER1$/check_http -I $ARG1$ -S
#       command_line     $USER1$/check_http -I $HOSTADDRESS$ -p $ARG1$ -S
}
and the server in localhost.cfg:

Code: Select all

define service{
        use                              local-service          ; Name of service template to use
        host_name                   tcecapmgr5ng01
        service_description      HTTPS
        check_command          check_https!10.153.106.250
        notifications_enabled   0
}
Locked