check_connecation.pl having unknow status
Posted: Thu Apr 24, 2014 12:09 am
Hi
i have Nagios® Core⢠3.4.4 on centos. I was trying to integrate the check_connection.pl with nagios but I am getting the Unknown status. but when I run via the command prompt I was getting the output given below.
/usr/local/nagios/libexec/check_connections.pl -w 20 -c 30 -u apache
OK - Established connections: 6
In Nagios I am getting the following error.
[1398163948] SERVICE NOTIFICATION: niraj;localhost;check_connection_apache;UNKNOWN;notify-service-by-email;Usage: -w warn -c crit [-u loginname
Command.cfg -----
define command {
command_name check_connection
command_line /usr/local/nagios/libexec/check_connections.pl --warning $ARG1 -critical $ARG2 --user $ARG3
}
localhost.cfg ------
define service{
use local-service,graphed-service ; Name of service template to use
host_name localhost
service_description check apache connection
check_command check_connection!20!30!apache
contact_groups admins,sms
}
i have Nagios® Core⢠3.4.4 on centos. I was trying to integrate the check_connection.pl with nagios but I am getting the Unknown status. but when I run via the command prompt I was getting the output given below.
/usr/local/nagios/libexec/check_connections.pl -w 20 -c 30 -u apache
OK - Established connections: 6
In Nagios I am getting the following error.
[1398163948] SERVICE NOTIFICATION: niraj;localhost;check_connection_apache;UNKNOWN;notify-service-by-email;Usage: -w warn -c crit [-u loginname
Command.cfg -----
define command {
command_name check_connection
command_line /usr/local/nagios/libexec/check_connections.pl --warning $ARG1 -critical $ARG2 --user $ARG3
}
localhost.cfg ------
define service{
use local-service,graphed-service ; Name of service template to use
host_name localhost
service_description check apache connection
check_command check_connection!20!30!apache
contact_groups admins,sms
}