tomcat monitor

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
berhan30
Posts: 15
Joined: Mon Jun 01, 2015 3:22 am

tomcat monitor

Post by berhan30 »

How to monitor apache tomcat for nagios in ubuntu:
-I download and put check_tomcat.pl in libexec
- I put the command in the file commands.cfg:

define command{
command_name check_tomcat
command_line /usr/local/nagios/libexec/check_tomcat.pl
}

- I put the command in the file servers.cfg:

define service{
use local-service ; Name of service template to use
host_name dspace
service_description Tomcat
check_command check_tomcat
notifications_enabled 1
}

warrning: Return code of 13 is out of bounds

note: the port of tomcat is 80
Last edited by tmcdonald on Thu Sep 03, 2015 9:09 am, edited 1 time in total.
Reason: Split from https://support.nagios.com/forum/viewtopic.php?f=7&t=33556 - please keep issues separate per topic.
monitoring the networks equipment and server : I have two problems
the first: how to configure a router contains more IP address (path).
the 2nd: how to configure a switch without level 2 IP address
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: tomcat monitor

Post by hsmith »

berhan30 wrote:How to monitor apache tomcat for nagios in ubuntu:
-I download and put check_tomcat.pl in libexec
- I put the command in the file commands.cfg:

define command{
command_name check_tomcat
command_line /usr/local/nagios/libexec/check_tomcat.pl
}

- I put the command in the file servers.cfg:

define service{
use local-service ; Name of service template to use
host_name dspace
service_description Tomcat
check_command check_tomcat
notifications_enabled 1
}

warrning: Return code of 13 is out of bounds

note: the port of tomcat is 80
What happens when you use the /usr/local/nagios/libexec/check_tomcat.pl plugin from the command line? That is usually the best place to start troubleshooting the issue.
Former Nagios Employee.
me.
berhan30
Posts: 15
Joined: Mon Jun 01, 2015 3:22 am

Re: tomcat monitor

Post by berhan30 »

How to monitor apache tomcat for nagios in ubuntu:
warring CRITICAL: http://localhost:80/manager/status?XML=true HTTP/1.1 404 Not Found
note: the port of tomcat is 80

define service{
use local-service ; Inherit default values from a temp$
host_name dspace
service_description Tomcat
check_command check_tomcat!80!admin!admin!10%,50%!5%,10%
}

define command{
command_name check_tomcat
command_line /usr/local/nagios/libexec/check_tomcat
}

Please detail
Thank you
monitoring the networks equipment and server : I have two problems
the first: how to configure a router contains more IP address (path).
the 2nd: how to configure a switch without level 2 IP address
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: tomcat monitor

Post by tmcdonald »

It looks like you are trying to run this against localhost. What is the IP address of the dspace host?
Former Nagios employee
berhan30
Posts: 15
Joined: Mon Jun 01, 2015 3:22 am

Re: tomcat monitor

Post by berhan30 »

IP address of the dspace host is 172.16.1.2
monitoring the networks equipment and server : I have two problems
the first: how to configure a router contains more IP address (path).
the 2nd: how to configure a switch without level 2 IP address
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: tomcat monitor

Post by hsmith »

berhan30 wrote:IP address of the dspace host is 172.16.1.2
And what happens when you run the command against that host from the command line. We should focus on getting the results you want in the command line before we worry about services.
Former Nagios Employee.
me.
Locked