Java Applications and Servers

check_java_threads

Description:

This plugin is meant to analyze every java process running locally and take metrics about which state each thread of this process has. It can (or can not) output a nagios-like output formatting for chart creation, and can also save automatically the thread dump to a file in case a determined type of thread is detected.

Current Version

1.0

Last Release Date

2015-08-14

Compatible With

  • Nagios 1.x
  • Nagios 2.x
  • Nagios 3.x
  • Nagios 4.x
  • Nagios XI

License

GPL


Project Files
Project Notes
LONG DESCRIPTION: This plugin is meant to analyze every java process running locally and take metrics about which state each thread of this process has. It can (or can not) output a nagios-like output formatting for chart creation, and can also save automatically the thread dump to a file in case a determined type of thread is detected. - usage: check_java_threads.py [options] IMPORTANT: As java process thread dumping must be done by the process owner, this plugin relies on the "su - login" shell feature. This said, you must either run it as root or with sudo privileges, otherwise you possibly won't get the expected behavior. If must at least set where your JAVA_HOME is and which login is the JAVA_OWNER of the desired java process to monitor. You should also define the thread state (stat_alert, default: STUCK) which you want to alert you and the minimum number of thread occurences for that alert (min_stat_alert, default: 0) for acting as a threshold. You can supress the nagios output format (the after '|' vars) with the -q or --quiet option. For saving a thread dump every time a interesting state is detected use the -c or --capture option. If your JDK is not supported by this plugin, feel free for editing it and getting it to work. Any upgrade/improvement/suggestion is really welcomed. SHORT DESCRIPTION: Run this plugin for nagios metrics and alerts when you have one or more stuck threads on a running java process. Use -c/--capture for saving a thread dump when a threshold is reached and -q if you don't want nagios chart creation. Compatibilities: * GNU/Linux * JRockit (any up to 1.6.x) * Hotspot (any up to 1.8.x) * Python (2.4 or bigger up to 2.x) Author: Marcelo Varge (marcelo.varge@gmail.com)
Reviews (0) Add a Review
Add a Review

You must be logged in to submit a review.

Thank you for your review!

Your review has been submitted and is pending approval.

Recommend

To:


From:


Thank you for your recommendation!

Your recommendation has been sent.

Project Stats
Rating
0 (0)
Favorites
0
Views
10,347