How to change the minimum and maximum heap size in WebSphere

Home > Search > How-to
  by

To change the heap size.

  1. Sign into the WebSphere web console.
  2. In the left panel, expand Servers > Server Types, and select WebSphere application servers.
  3. Select the application server.
  4. Expand Java and Process Management and select Process definition.
  5. Select Java Virtual Machine.
  6. Update the Initial heap size and/or Maximum heap size.
  7. Select Apply.
  8. Select Save.
  9. Restart the JVM for the change to take effect.

In this example, the initial heap size is 64 MB and the maximum heap size is 256 MB.

 

Sign onto the server and issue the following command to ensure the JVM has the appropriate initial heap value at runtime. In this example, the JVM has an initial heap value of 64 MB.

~]# ps -ef | grep jvm_name | sed "s| |\n|g" | grep -Xms
-Xms64m

 

Issue this command to ensure the JVM has the appropriate maximum heap value at runtime. In this example, the JVM has an maximum heap value of 256 MB.

ps -ef | grep jvm_name | sed "s| |\n|g" | grep -Xmx
-Xmx256m

 

If you have a tool that produces a graph of the heap, the graph can to used to know what would be a good minimum heap size. For example, in this graph, the steady state for the minimum heap is around 200 MB. In this scenario, a miminum heap of 128 MB would probably be good.

 



Add a Comment




We will never share your name or email with anyone. Enter your email if you would like to be notified when we respond to your comment.




Please enter in the box below so that we can be sure you are a human.




Comments