Reported memory overflow error when booting tomcat locally: Java.util.concurrent.ExecutionException:java.lang.OutOfMemoryError:PermGen space

Source: Internet
Author: User

Problem Analysis:

PermGen space is the full name of permanent Generation space, refers to the memory of the permanent storage area, this block of memory is mainly stored by the JVM class and meta information, class is loader will be placed in PermGen Space, unlike the heap area where the class instance (Instance) is stored, the GC (garbage Collection) does not clean up permgen space during the main program run time, so if you have a class in your application, PermGen space errors are most likely to occur when the Web server pre-compile the JSP. If you have a large number of third-party jars under your web app that are larger than the JVM's default size (4M), this error message will be generated.

Workaround:

Step 1: Open MyEclipse, click on the button above the window, select the bottom of the preferences this button, open the interface as follows

Step 2: Choose Java This option, click Java This option installed JREs this appears to the right of the interface, as shown in:

Step 3: Appear on the right side of this option, double-click the open page, in the default VM arguments this option to fill in the following statement:

-xx:permsize=256m-xx:maxpermsize=256m

This way, you can increase the memory of the virtual machine, which solves the problem.

Other Workarounds:

Manually setting the MaxPermSize size

(a) under Windows system, modify Tomcat\bin\catalina.bat and add the following line on the "Echo Using catalina_base:"%catalina_base% "":
Set java_opts=%java_opts%-server-xx:permsize=128m-xx:maxpermsize=512m

(b), under the Linux system, modify the tomcat\bin\catalina.sh and add the following line on the "echo" Using catalina_base: $CATALINA _base "":

java_opts= "$JAVA _opts-server-xx:permsize=128m-xx:maxpermsize=512m"

Reported memory overflow error when booting tomcat locally: Java.util.concurrent.ExecutionException:java.lang.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.