Page 1 of 1

Nagios Core-3.5.1 Url Monitoring

Posted: Mon Nov 12, 2018 12:05 pm
by mani479
Hi

I have been trying to Monitor Url using Nagios-3.5.1

./check_http -H http://www.testing.com -f follow -u "/vap/"
HTTP OK: HTTP/1.1 200 OK - 15003 bytes in 0.169 second response time |time=0.169042s;;;0.000000 size=15003B;;;0



But when i execute this command in script it's not working

# 'check_http4' command definition
define command{
command_name check_http4
command_line $USER1$/check_http -H $HOSTNAME$ -f $ARG1$ -u $ARG1$
##

But it's not working

Can you please help me with this

Thank you,
Mani

Re: Nagios Core-3.5.1 Url Monitoring

Posted: Mon Nov 12, 2018 12:42 pm
by scottwilkerson
Can you show what is in the HOSTNAME in the host object and the $ARG1$ and $ARG2$ of the service definition

Also, it looks like you inadvertanly have $ARG1$ twice in the command definition

Code: Select all

# 'check_http4' command definition
define command{
command_name check_http4
command_line $USER1$/check_http -H $HOSTNAME$ -f $ARG1$ -u $ARG1$
##
you may want

Code: Select all

# 'check_http4' command definition
define command{
command_name check_http4
command_line $USER1$/check_http -H $HOSTNAME$ -f $ARG1$ -u $ARG2$
##
but we would need to see the service definition to recommend the command