Hi Yoav, > Yes to 1, and likely yes to 2. Check out the > different garbage > collector implementations, and the directives for > setting old and young > generation sizes. Your case is a classic one for > setting a small old > generation size relative to the young generation > size: maybe even a 10-1 > or slightly less ratio of young size to old size.
I've never checked this page out before, but at your prompting I found it today: http://java.sun.com/docs/hotspot/VMOptions.html I believe the docs are telling me that the default value of XX:NewRatio=12 for Intel. Is that correct? If that's true, should I just leave the default? I have no experience with setting any of these values. I've always used the JVM right out of the box (my ignorance). What would be a minimum set of parameters to span this space? Thanks - % --- "Shapira, Yoav" <[EMAIL PROTECTED]> wrote: > > Hi, > > >I've got Tomcat 4.1.29 installed to run as a > service > >under JDK 1.4.1_05 on this Windows 2000 server. The > >Tomcat memory settings on startup are -Xms64m and > >-Xmx1024m. The server has 512MB of physical RAM > > It's not a good idea to set -Xmx to a higher amount > than the amount of > physical RAM: the JVM will thrash once it reaches > much less than 512MB. > > >My understanding is that Java's garbage collection > >will reclaim heap-allocated memory to the JVM, but > not > >necessarily to the OS. Is this true? What this > means > >is that a Windoze server admin could look at the > task > >manager and see a large memory usage for Tomcat, > but > >that doesn't necessarily reflect Tomcat's current > >usage. > > > >It's more like a high water mark on a pier: it'll > show > >the highest value that Tomcat has used, but the > real > >value will be lower if the garbage collector runs > and > >the tide goes out. If you read a lot of objects > into > >session you could end up with a big high water > mark. > > Your understanding is good and correct on the above > issues. > > >(1) Is my understanding of the interaction between > the > >JVM and OS memory management correct? > >(2) Are there any other tuning settings for Tomcat > >that I need to look at? > > Yes to 1, and likely yes to 2. Check out the > different garbage > collector implementations, and the directives for > setting old and young > generation sizes. Your case is a classic one for > setting a small old > generation size relative to the young generation > size: maybe even a 10-1 > or slightly less ratio of young size to old size. > > And there's the ever-present (which is why it's > often forgotten) advice: > you might want to get more physical RAM. It's > pretty cheap, and 512MB > isn't that much for a server nowadays. > > Yoav > > > > This e-mail, including any attachments, is a > confidential business communication, and may contain > information that is confidential, proprietary and/or > privileged. This e-mail is intended only for the > individual(s) to whom it is addressed, and may not > be saved, copied, printed, disclosed or used by > anyone else. If you are not the(an) intended > recipient, please immediately delete this e-mail > from your computer system and notify the sender. > Thank you. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: > [EMAIL PROTECTED] > For additional commands, e-mail: > [EMAIL PROTECTED] > __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
