tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Re: Increase Heapsize
Date Wed, 19 Jul 2006 16:56:00 GMT
I understand.
The webapp is a content management site which has been producing out of 
memory errors.
The server has 16GB RAM which is quite significant.
Curious:are there any other adantages to setting them the same?

I'm assuming that
going from:
-Xms512 -Xmx1024
-Xms512 -Xmx2048

is less desirable than
-Xms512 -Xmx1024 
-Xms2048 -Xmx2048

Understandable this may not apply in every case

Christopher Schultz <>
07/19/2006 09:52 AM
Please respond to "Tomcat Users List"

        To:     Tomcat Users List <>
        Subject:        Re: Increase Heapsize


>  The current values on our system are:
> -Xms512   -Xmx1024
> so if I wished to increase the heapsize, can you give an example what
> the new figures would be?

You really need to do more research on your own:

-Xms = set initial Java heap size
-Xmx = set maximum Java heap size

If you are currently allocating 1GB (-Xmx1024), then you probably want
to set it to something /bigger/ than 1GB. Perhaps 1.5GB:


Upon the recommendation of another poster, you might want to set the
initial and the maximum to the same thing (that will allocate the entire
Java heap at once, instead of forcing the memory manager to grow the
heap during runtime):

-Xms1536 -Xmx1536

It's up to you to decide what your heap size should be. You need to
understand the operation and needs of your application, as well as
pattern of usage by your users to choose a good heap size. You can
certainly allocate a HUGE heap and cross your fingers, but that is not
always a good strategy -- especially when you are limited by physical
RAM as well as the other processes running on your server.

Hope that helps,

This communication (including any attachments) may contain privileged or
confidential information intended for a specific individual and purpose, 
and is protected by law.  If you are not the intended recipient, you should
delete this communication and/or shred the materials and any attachments and
are hereby notified that any disclosure, copying, or distribution of this
communication, or the taking of any action based on it, is strictly prohibited.

Thank you.

View raw message