check_http plugin usage

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
formher
Posts: 3
Joined: Sat Mar 31, 2018 6:25 am

check_http plugin usage

Post by formher »

Hi,

I am trying to setup monitoring for our internal web services http endpoints but I am not sure how to indicate the url in check_http plugin.
I see this example in localhost.cfg file:

Code: Select all

define service{
        use                             local-service         ; Name of service template to use
        host_name                       localhost
        service_description             HTTP
	check_command			check_http
	notifications_enabled		0
        }
but when I change it to e.g below, and restart the nagios it doesn't even start. where and how should I put the endpoint checks?

Code: Select all

define service{
        use                             local-service         ; Name of service template to use
        host_name                       localhost
        service_description             HTTP
	check_command			check_http_url!www.google.com
	notifications_enabled		0
        }
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: check_http plugin usage

Post by scottwilkerson »

First we need to see hou you have the command for check_http defined

Then we can help you craft the URL, you do not change the command name, you change the arguments.

https://assets.nagios.com/downloads/nag ... acros.html
Former Nagios employee
Creator:
ahumandesign.com
enneagrams.com
formher
Posts: 3
Joined: Sat Mar 31, 2018 6:25 am

Re: check_http plugin usage

Post by formher »

Thank you for responding. I figured out what was problem already.
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: check_http plugin usage

Post by scottwilkerson »

Glad to hear it is resolved
Former Nagios employee
Creator:
ahumandesign.com
enneagrams.com
Locked