Thursday, March 28, 2013

Modifying JVM Heap Size for WebLogic Server Instances

Version: WebLogic 10.3.5
Description: To improve OIM performance, it may be necessary to increase the JVM Heap size for the WebLogic servers.

Increase JVM Memory

Method One
All your server instances will have the same JVM heap sizes using this method.
1. Modify the "setSOADomainEnv.sh" script which can be found in "<domain_home>/bin".
cd /home/oracle/Oracle/Middleware/user_projects/domains/oim_domain/bin
vi setSOADomainEnv.sh

2. Modify the values for DEFAULT_MEM_ARGS and PORT_MEM_ARGS.
#Sample values
DEFAULT_MEM_ARGS="-Xms768m -Xmx1536m"
PORT_MEM_ARGS="-Xms1024m -Xmx1792m"

3. Execute the "setSOADomainEnv" script.

To check the JVM heap size of your servers, execute the following command:
#Check AdminServer process
ps -ef | grep AdminServer

#Check OIMServer process
ps -ef | grep oim_server1



Method Two
With this approach, you will be able to specify different JVM heap sizes for your WebLogic server instances. This method requires Node Manager to control your servers. Since the AdminServer doesn't require much resource compare to the managed servers, the JVM heap size of the AdminServer should be lower than the JVM heap size of your managed servers.

1. Login to the WebLogic Administration Console.

2. Navigate Servers -> [Server Name] -> Configuration -> Server Start.

3. Put ms and mx values in the Arguments field. Eg. -Xms1536m -Xmx2048m






When you start your servers with node manager, the latter arguments will override the JVM heap size arguments specified at the beginning.



To actually verify those arguments are being used, navigate to Servers section and display the Heap Size Current and Heap Free Current columns.


1 comment: