1. Tomcat can use 128 MB of memory by default. In large application projects, this memory is insufficient and may cause the system to fail. A common problem is the error of Tomcat memory overflow. the out of memory (insufficient system memory) causes the client to display the Error 500. Generally, the problem can be solved by adjusting the memory usage of Tomcat.
Modify the "% tomcat_home % \ bin \ Catalina. Bat" file in windows and add the following settings at the beginning of the file: Set java_opts =-xms256m-xmx512m
Modify the "% atat_home % \ bin \ Catalina. Sh" file in Linux and add the following settings at the beginning of the file: java_opts = '-xms256m-xmx512m'
Here,-XMS sets the initial memory size and-xmx sets the maximum memory that can be used.
2. The Catalina. BAT file is no longer available in Tomcat 6. In this case, run the % atat_home % \ bin \ tomcat6w.exe file to modify the values of initial memory pool and maximum memory pool, which are 256 and 512 respectively.
Original article: http://www.cnblogs.com/ztf2008/archive/2008/12/17/1357017.html
Tomcat6 memory insufficiency and Solution