Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6718117
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T08:55:54+00:00 2026-05-26T08:55:54+00:00

We have a Nagios check that checks the heap memory state on some Tomcat

  • 0

We have a Nagios check that checks the heap memory state on some Tomcat instances. The command it uses to get metrics back from the VM is the following:

java -jar /usr/java/cmdline-jmxclient-0.10.3.jar - localhost:17757 java.lang:type=Memory HeapMemoryUsage

Which produces output such as:

committed: 132579328
init: 134217728
max: 401014784
used: 18831512

An alert is kicked off if the value against used is greater than 90% of the value against max. This seems flawed to me, mainly because the value of max can go down as well as up 🙂

What information should we be using to monitor correctly the consumption of heap space?

Should I be comparing max with the value of Xmx?

I can retrieve the value of Xmx using the following command:

java -jar /usr/java/cmdline-jmxclient-0.10.3.jar - localhost:17757 java.lang:type=Runtime InputArguments

Is there a better way?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T08:55:55+00:00Added an answer on May 26, 2026 at 8:55 am

    From my observations, the “max” value fluctuates. Monitoring an example Java process, the used heap varies as you’d expect, but the committed and max values also size dynamically as the used heap approaches those limits (I believe the ratios are configurable).

    In my case, the Xmx flag was set to 9 GiB and strangely, the committed and max values occasionally exceeded this (9.2 GiB)?

    Java tends to make aggressive use of available heap space, so a used heap size occasionally hitting 100% wouldn’t bother me. Instead, I’d be more interested in the average of the last 5, 10 and 15 minutes etc. If the used heap stays above 90% for long periods, you may have a problem – checking your GC overhead would be a good indicator (and any OOME’s obviously).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a script that polls a MySQL database (Nagios, specifically) for the date/time
Have some dates in my local Oracle 11g database that are in this format:
I have setup a nagios monitoring and configured check_http plugin to check for a
I have a production system that uses ActiveMQ (5.3.2) to send messages from server
Have you managed to get Aptana Studio debugging to work? I tried following this,
a newbie question I have a Django project with two applications core and nagios
Just installed Nagios 3.2 and have it monitoring 4 or 5 windows hosts as
I have a postgres function that returns two columns result, data (int), (text) If
I have developed an app that runs as a windows service and regularly does
In this article http://nagios.sourceforge.net/docs/3_0/eventhandlers.html#example they show how to get arguments from nagios to shell

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.