Peter,
I'm a bit confused by your answer, that if you have 1 gig of ram on a box it's ok
to set the heap to 1 gig. Through reading your other postings I know that you have coded
your own JVM based on Sun's source, so you know your stuff. And I know that you know
the heap is just the new and tenured gen, not the whole JVM. Hopefully you can clear
something up for me.
We run JBoss on Solaris. I have a basic formula that I use for my JVM memory calculations
which is:
Total JVM memory footprint = JVM housekeeping + heap + permgen
In the formula above:
* JVM housekeeping (this is my own stupid term) = native code + JVM runtime data (code
cache, etc.).
* heap = new gen + tenured gen
* permgen = permgen
When I run a prstat on the JBoss pid, what I see for SIZE is Total JVM mem footprint. I
can do my little calculations with stats that I get from jmap -heap and come up with
consistent sizes for JVM housekeeping across our boxes, depending on the particular
deployment (and other things like # of threads).
In our case, we pre-allocate (set min=max) for heap and permgen.
I haven't yet found a option specifically for setting memory for the native code or
runtime data, I don't know if anyone would want to.
Anyway (there really is a question buried here :), if you have a 1 gig box, preallocate 1
gig for heap (new and tunured), preallocate 128 or whatever for perm, knowing that the
native code and runtime data might want 200 or 300 meg, aren't you going to be living
in swap city?
I'm going to have to test this out. I've been leaving 500 meg free on our Solaris
boxes for the OS and the monitoring stuff the network guys run.
Thanks,
Jerry
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4019119#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...