Solutions for Outofmemoryerror:permgen Space

Source: Internet
Author: User

MyEclipse launched Tomcat, reported Outofmemoryerror:permgen space solution

posted on July 27, 2012

This is a very simple question, but the search for a half-day, found that we write a blog is too not serious, many people are not rigorous, will mislead everyone. Here's your own summary:

1. If you are starting Tomcat error individually, you can modify the Catalina.bat file as follows (assuming it is in Windows):

After the line "Rem-–execute the requested Command —————————————", "Echo Using catalina_base:"%catalina_base% "" is added before:

1 set JAVA_OPTS=%JAVA_OPTS% -server -XX:PermSize=512m -XX:MaxPermSize=512m

Looking at a lot of blogs, someone has added a quotation mark to the front, someone who doesn't distinguish between a. bat file or a. sh file. Someone has added-xx:maxnewsize=512m, someone written in lowercase m and uppercase M mixed. Although it is convenient for me to write a blog, it is a great problem for the people who use it.

2. If it is in myeclipse, it can be shown in the interface:

In the optional Java VM arguments, fill in the following:

1 -Xms512m -Xmx512m -XX:PermSize=512m -XX:MaxPermSize=512m

As for-xx:maxnewsize=512m there is no use, the size of M there is no difference, sorry, I do not have time to carefully scrutinize, just want to say, I hope you write a blog when the heart point, professional.

Workaround for Outofmemoryerror:permgen space

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.