Tomcat6 memory insufficiency and Solution

Source: Internet
Author: User

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

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.