?
Solved

Setting the Heap Size for the JVM in JBOSS Application Server 4.0.x

Posted on 2007-10-16
5
Medium Priority
?
3,234 Views
Last Modified: 2013-12-02
Hi,

1) How do i set the heap size for the JBOSS Application Server Instance , I need to change the  MEM_ARGS=-Xms128m -Xmx256m,

ex: java --Xms128m -Xmx256m where can i edit this setting for my current JBOSS Application Server.

2) How can i tell JBOSS to use a  specific JDK. I am using JBOSS version 4.0.x
0
Comment
Question by:zraees
  • 2
  • 2
4 Comments
 
LVL 19

Accepted Solution

by:
ramazanyich earned 2000 total points
ID: 20116135
If you are starting it on windows then edit file $JBOSS_HOME/bin/run.bat and add two lines just after @echo off line
set JAVA_HOME=c:\jdk1.5
set JAVA_OPTS=-Xms128m -Xmx256m

of course c:\jdk1.5 should be replaced by path of your Java home.

ON UNIX:
edit file $JBOSS_HOME/bin/run.conf there is commented JAVA_HOME setting. Uncomment it and put path to your java home.
Also there you can find JAVA_OPTS definition. By default it is set to -server -Xms128m -Xmx512m -Dsun.rmi.dgc.client.gcInterval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000
just modify it.

0
 
LVL 2

Expert Comment

by:PallaviJain20
ID: 23323391
Please set this para meter in JBoss_home/bin/run.conf

if [ "x$JAVA_OPTS" = "x" ]; then
   JAVA_OPTS="-Xms128m -Xmx512m -Dsun.rmi.dgc.client.gcInterval=3600000 -Dsun.rmi.dgc.server.gcInterval=3600000"
fi

whatever size you want to set
0
 
LVL 19

Expert Comment

by:ramazanyich
ID: 23325788
run.conf read only on UNIX environment.
0
 
LVL 2

Expert Comment

by:PallaviJain20
ID: 23333198
For windows environment the run.bat has all parameter so open with text editor and set there
0

Featured Post

Prep for the ITIL® Foundation Certification Exam

December’s Course of the Month is now available! Enroll to learn ITIL® Foundation best practices for delivering IT services effectively and efficiently.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Configure Web Service (server application) I. Configure security for Web Services methods First, we need to protect Session bean which implements the service: 1. Open EJB deployment descriptor (ejb-jar.xml) in the EJB project that contains you…
Most of the developers using Tomcat find it easy to configure the datasource in Server.xml and use the JNDI name in the code to get the connection.  So the default connection pool using DBCP (or any other framework) is made available and the life go…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an anti-spam), the admin…
Please read the paragraph below before following the instructions in the video — there are important caveats in the paragraph that I did not mention in the video. If your PaperPort 12 or PaperPort 14 is failing to start, or crashing, or hanging, …
Suggested Courses

807 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question