Java – JVM tuning in JBOSS AS 7

javajbossperformance-tuning

Can anyone explain as to where and how do I configure the following JVM parameters to tune JBOSS. I am using the latest JBOSS AS 7.

I am using openJDK-6 on Linux.

The following are the parameters which I have used for tuning Tomcat-7 and I need to know how & where do I put these in JBOSS:

To configure Java heap:

-server -XX:NewSize=700m -XX:MaxNewSize=700m -Xms2048m -Xmx2048m -XX:MaxPermSize=200m 
-XX:SurvivorRatio=6 -XX:TargetSurvivorRatio=90 -XX:MaxTenuringThreshold=15

To Configure Garbage Collector:

-XX:+UseParNewGC -XX:+UseConcMarkSweepGC -XX:+CMSParallelRemarkEnabled XX:ParallelGCThreads=16 -XX:+CMSCompactWhenClearAllSoftRefs -XX:CMSInitiatingOccupancyFraction=85 -XX:+CMSScavengeBeforeRemark -XX:+CMSConcurrentMTEnabled -XX:ParallelCMSThreads=2

Best Answer

If you use the default startup scripts it should be sufficient to put this in the environment variable "JAVA_OPTS".

https://community.jboss.org/wiki/JavaOpts