how to monitor Web URL

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
miyappan
Posts: 57
Joined: Thu Feb 11, 2016 5:42 am

how to monitor Web URL

Post by miyappan »

how to monitor Web URL. im getting following error. NRPE: Command 'check_website' not defined.

below are the configuration.

Nrpe.cfg

command[check_website]=/usr/local/nagios/libexec/check_website -s //aep.altimetrik.com/Mentor-Mentee
...............................................................................................................................

command.cfg

#'check_website' command definition
define command{
command_name check_website
command_line $USER1$/check_website -H $HOSTADDRESS$ $ARG1$
}

# 'check_website_response' command definition
define command{
command_name check_website_response
command_line $USER1$/check_website_response.sh -u $ARG1$ -w $ARG2$ -c $ARG3$
}


..............................................................................................................

#################################################################################
# HOST DEFINITION #
# #
#################################################################################
define host{
use linux-server
host_name Mentor Mentee
alias MentorMentee
address 192.168.85.40
}

##################################################################################
# SERVICE DEFINITION #
# #
##################################################################################
define service{
use generic-service
host_name Mentor Mentee
service_description Mentor status
check_command check_nrpe!check_website
}
Attachments
check_website.PNG
rkennedy
Posts: 6579
Joined: Mon Oct 05, 2015 11:45 am

Re: how to monitor Web URL

Post by rkennedy »

Which Nrpe.cfg file did you put that line into? Can you paste the whole file here? Did you restart xinetd / NRPE after doing so?

Additionally, is there a specific reason you're running a check_http through NRPE, rather than just using check_http from the Nagios machine?
Former Nagios Employee
Locked