tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Darryl Lewis <>
Subject RE: Bash script for monitoring status of the Tomcat server
Date Mon, 02 Apr 2012 23:20:55 GMT
Try JavaMelody. It does a lot of monitoring straight out of the 'box'.
For there, it is a small step to use wget to screen scrape values from Melody and send emails
once they exceed a threshold.

-----Original Message-----
From: Christopher Schultz [] 
Sent: Tuesday, 3 April 2012 5:50 AM
To: Tomcat Users List
Subject: Re: Bash script for monitoring status of the Tomcat server

Hash: SHA1


On 4/2/12 3:28 PM, Caldarale, Charles R wrote:
>> From: Miguel González Castaños
>> [] Subject: Bash script for
>> monitoring status of the Tomcat server
>> I would like to run a bash script to monitor these values and
>> warn me if the reach a certain level. Also a tool that generates
>> some graphs would be great.
> Not quite sure how you can put "bash" and "graphs" together, but
> nonetheless...
> 2) Use wget or curl to access Tomcat's text-mode manager app and 
> parse the results.

+1 -- and use the JMXProxyServlet, which lets you query specific
components like the connectors. We've been doing this lately to great

You can use a tool like rrdtool to store the data and generate
nice-looking graphs over time. You can also easily use the same feed
to do real-time monitoring using a tool like Nagios, Ichinga, etc.

> 3) Use a command-line JMX tool like jmxsh
> ( to extract information and parse
> out whatever you want.

While this is a tempting idea, when you start probing many different
values via JMX, you'll find that starting a dozen JVMs and connecting
via JMX starts to strain the server unnecessarily. That's why I
recommend using JMXProxyServlet -- you get the power of JMX without
actually making a JMX connection.

- -chris
Version: GnuPG/MacGPG2 v2.0.17 (Darwin)
Comment: GPGTools -
Comment: Using GnuPG with Mozilla -


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message