-
1. Re: How to know CURRENT HEAP SIZE USED, FREE HEAP SPACE, TOT
mazz Mar 28, 2008 9:31 AM (in response to vijayneema)Keep your eye on http://www.rhq-project.org - the RHQ Middleware Management Tool. No JBossAS plugin is out in the open yet, but a) you can write your own or b) wait and see if the community produces one.
-
3. Re: How to know CURRENT HEAP SIZE USED, FREE HEAP SPACE, TOT
mazz Mar 28, 2008 9:35 AM (in response to vijayneema)Oh, but you can use the RHQ JMX plugin - you should be able to import your platform and connect to your JBossAS app server as a "JMX Server" and monitor it that way. I haven't tried that but it may work if you are looking for something now.
-
4. Re: How to know CURRENT HEAP SIZE USED, FREE HEAP SPACE, TOT
mazz Mar 28, 2008 9:55 AM (in response to vijayneema)And yet another possibility is purchase JBoss ON - our 2.0 is currently in beta to be released in several weeks. See our short demo at https://network.jboss.com/confluence/display/JON2/Demo-Intro
-
5. Re: How to know CURRENT HEAP SIZE USED, FREE HEAP SPACE, TOT
csaldanh Mar 28, 2008 1:07 PM (in response to vijayneema)Doesn't this MBean give all the information such as memory used , total memory etc.
jboss.system:type=ServerInfo
You could use the jmx-console to access the information of this mbean. -
7. Re: How to know CURRENT HEAP SIZE USED, FREE HEAP SPACE, TOT
vijayneema Mar 31, 2008 4:52 AM (in response to vijayneema)Thanks everyone!!
For your better understanding, here is the code I am using with weblogic to fetch the required information:import weblogic.jndi.Environment; import weblogic.management.MBeanHome; import weblogic.management.runtime.JVMRuntimeMBean; Environment env = new Environment(); env.setProviderUrl("t3://weblogicbox:1111"); env.setSecurityPrincipal("abcd"); env.setSecurityCredentials("abcd"); Context ctx = env.getInitialContext(); home = (MBeanHome) ctx.lookup(MBeanHome.ADMIN_JNDI_NAME); JVMRuntimeMBean serverRuntime = (JVMRuntimeMBean) home.getRuntimeMBean(serverName, "JVMRuntime"); System.out.println((serverRuntime.getHeapSizeCurrent()-serverRuntime.getHeapFreeCurrent())/1024);
Note that this program is running on a different box & fetching information from a different box running weblogic.
Thanks a lot