Dear Wiki user, You have subscribed to a wiki page or wiki category on "Tomcat Wiki" for change notification.
The following page has been changed by markt: http://wiki.apache.org/tomcat/FAQ/Memory The comment on the change is: Add question list to start. Add Yourkit to list of profilers. ------------------------------------------------------------------------------ * [http://marc.theaimsgroup.com/?t=103011379700006&r=1&w=2 Tomcat Out of memory] * [http://marc.theaimsgroup.com/?t=104519961700002&r=1&w=2 Tracking memory usage over time] - Also look at [http://java.quest.com/jprobe/jprobe.shtml JProbe], or [http://www.borland.com/optimizeit/ OptimizeIt], or other profiling tools. Lots of people recommend these tools. This is not an endorsement for them, I just notice other people like them. + Also look at [http://java.quest.com/jprobe/jprobe.shtml JProbe], [http://www.yourkit.com/ YourKit] or [http://www.borland.com/optimizeit/ OptimizeIt], or other profiling tools. Lots of people recommend these tools. This is not an endorsement for them, I just notice other people like them. === JSP Recompilation === If your application uses JSPs which are frequently recompiled at runtime, e.g. headers that change value hourly, please make sure to read the JSP HOW-TO page and RELEASE NOTES documents. You may wish to tune the JSP compiler configuration to prevent memory leaks. Of course, these are documents you should have read by now anyways.. == Questions == + 1. [#Q1 How do I adjust memory settings?] + 1. [#Q2 Why do I get {{{OutOfMemoryError}}} errors?] + 1. [#Q3 How much memory is Tomcat/webapp/??? using?] + == Answers == - '''How do I adjust memory settings?''' + [[Anchor(Q1)]]'''How do I adjust memory settings?''' First look at {{{java -X}}} to determine what parameters to set. Then you can set them via the environment variable {{{JAVA_OPTS}}}. Read the files catalina.bat or catalina.sh for more information on JAVA_OPTS. - '''Why do I get {{{OutOfMemoryError}}} errors?''' + [[Anchor(Q2)]]'''Why do I get {{{OutOfMemoryError}}} errors?''' Many reasons. @@ -35, +39 @@ * Not actually a reason - but on your particular platform, look at the {{{java -X}}} options. They may be VERY helpful. * [http://opensource2.atlassian.com/confluence/spring/pages/viewpage.action?pageId=2669 Your classloaders are not being garbage collected]. - '''How much memory is Tomcat/webapp/??? using?''' + [[Anchor(Q3)]]'''How much memory is Tomcat/webapp/??? using?''' * To find out how much memory Tomcat is using, you might be able to use the {{{Runtime}}} class provided by the JDK. * You can't find out how much memory a webapp is using. The JVM doesn't give us these detail. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]