how to generate heap dump from jboss-eap-6.0 - jboss6.x

Hello All,
how to generate heap dump from jboss-eap-6.0 ?
below link talks about JBoss AS 6.x but i am looking for jboss-eap-6.0, seems jboss-eap-6.0 doesn't JMX bean support. i know Jmap command but i am more of looking how to trigger manually from jboss-eap-6.0
http://www.jochenhebbrecht.be/site/2012-12-12/java/creating-a-java-heapdump-in-jboss-6x

Try JVisualVM. It comes with the JDK, you should see it in your bin folder next to java/javac
It has options to profile and dump a running JVM. It can connect to remote JVMs, check here on how to enable JMX port, if JBOSS doesn't have that by default.

Related

Web interface for managing Tomcat services

I have tons of tomcat servers, they are all in a virtual machine. At the moment there is a need to develop a web panel, where I can track the statuses of servers, change their configurations, stop and restart. Actually the question itself: with what technologies can I do this. Previously, there was an idea to use the playbook ansible.
How can I at least display the names of my servers on the page?
There are two standard ways to monitor Tomcat:
you can use Tomcat Manager, especially its text interface,
you can use JMX directly or through the JMX Proxy Servlet. On Tomcat's webpage you can find a not so up-to-date list of MBeans. For some MBeans you'll have to fire up jconsole and explore the names yourself.

Wildfly : Is there any overhead enabling ejbs and datasources statistics?

In the wildfly config file (standalone.xml), it is possible to enable statistics for the ejb and datasources susbsystems
I would like to enable them to get useful infos at runtime (invocations, execution times,...)
But is it something that can be activated on a production server ?
Is there any overhead ?
The answer to both question is yes :) you can activate it and there will be an overhead.
You can use the jboss-cli to enable/disable the stats without requiring a restart of the server.

Enabling verboseGC on WebSphere Application Server

I have an issue while enabling verboseGC. I have 8 JVMs (clustered) and out of those, 3 JVMs have been already enabled for verboseGC. I am now enabling verboseGC on the remaining 5 JVMs.
Once I enabled verboseGC at below path (on the 'Runtime' tab) , I have restarted the JVMs.
Application servers > applicationservername > Process definition > Java Virtual Machine.
But when I look for verboseGC logs in the native_stderr.log file, I don't see anything logged. When I went back to the above path, I found that the 'Verbose garbage collection' setting on the 'Runtime' tab was unchecked automatically.
Has anyone encountered a similar issue? What was done to fix it ?
Changes made on the 'Runtime' tab do not persist across restarts of WebSphere Application Server. Any such changes are applied to the currently running JVM process, but are lost when the process is restarted. For the VerboseGC setting to be applied permanently, update the setting under the Configuration tab. Then restart the server for the changes to take effect.
As for the log not being written, verboseGC output is written to native_stderr.log on AIX, Linux, & Windows and to native_stdout.log on Solaris & HP-UX. If you are using Solaris or HP-UX, you have to set Generic JVM Arguments for the logging to work correctly. Refer to this IBM Document for details.

What arguments can we add to 'Generic JVM Argument' to display the GC info in RAD Websphere v7.5?

In RAD WebSphere, I want to add the some arguments to the JVM, in order to display some information about the garbage collection. I notice that this action is in the Administration Console-->Server-->Application Server-->Server1-->Java and Process Management-->Process Definition-->Java Virtual Machine-->Generic JVM Argument.
Normally in Oracle JDK, there are arguments that we can add like: -Xms1000m -Xmx1000m -XX:PermSize=256m -XX:MaxPermSize=256m -XX:MaxNewSize=500m -XX:NewSize=500m -XX:+PrintGCDetails -XX:+PrintGCTimeStamps -Xloggc:/home/sherpa/Sherpa/Server/log/gc.log -XX:+HeapDumpOnOutOfMemoryError.
I tried to add these arguments in it, but it seems that it doesn't work with these arguments.
So is there some specific arguments that can only be used in RAD WebSphere? What arguments can we use in RAD?
I am looking forward to your opinions!
If you're running Websphere application server, you'll be using the IBM JVM.
You can get additional information about garbage collection using the -verbose:gc option.
You can find more information about the output produced by this option on this Knowledge Center page.
RAD is just your developing environment, an IDE. You can have WebSphere Application Server runtime as test environment installed together with RAD, but it is separate server, it just happens to be already integrated in the Servers View.
So in general all rules related to WebSphere apply. WebSphere runs IBM JVM, so if you want to enable verbose gc check the WebSphere infocenter, and do not provide Oracle JVM params as they simply dont work in IBM JVM :-)
So for WebSphere you should enable it via admin console in the JVM settings page, just call it via browser, but it is available to invoke it from RAD in servers view also.
For details check:
Java virtual machine settings
Garbage Collector options - to be specified via Generic JVM options

How do I start my grails dev server in single threaded mode?

grails run-app will start my app in an embedded tomcat server.
I would like to configure this embedded server so that only a single request processor thread is available and that multiple threads are processed serially rather than concurrently (similar to default webrick behaviour in the rails world)
Is it possible? If so, how do I do it?
As far as I know, this is not directly supported by the Tomcat plugin. But you could easily modify the Tomcat plug-in and run your own version.
If you look at the class org.grails.tomcat.TomcatServer, you will see it starts a Tomcat instance.
Here is the doc for this class: http://tomcat.apache.org/tomcat-7.0-doc/api/org/apache/catalina/startup/Tomcat.html
There is a getConnector() method which will return the default HTTP connector. Once you have it, you can probably change the settings, like maxThreads.
But be careful the performance will be awful. But I guess you already know that.

Resources