Tomcat 6.x Perm Memory leakage, 6. xperm

Source: Internet
Author: User

Tomcat 6.x Perm Memory leakage, 6. xperm
Tomcat 6.x
The last modification time of JSP files exceeds the current system time, leading to Memory leakage in the Perm zone (java Memory pool CMS Perm Gen)


Scenario:
Because the Test Service needs to simulate cross-day testing, the server implementation is usually modified to complete the test service. After the test is completed, the system time is not synchronized immediately, but is directly released and launched, the problem arises. Because the traversal time is used for packaging, the last modification time of all packaged files is crossed.
For example, today is: 2015.1.1. in order to complete the test, the system time is crossed to 2015.1.5. At this time, the last modification time of all files packaged is no.

This was originally just a traversal of the last modification time of the file. Because Tomcat supports the hot Release Feature of JSP, changes to the JSP file will be detected every 4 seconds, because the last modification time of the JSP file exceeds several days after the current system time, Tomcat will re-trigger the hot release every 4 s (Tomcat hot release delay time) in these days, to put it bluntly, the custom Class loading mechanism is used to re-load the Class. Because JDK1.6 Class info exists in the Perm zone, the memory recovery in this region is extremely demanding, this causes a large number of new classes to be loaded, resulting in memory overflow in the Perm area.


The modification method is to synchronize the Time of the Publishing Server.
This problem has been fixed in Tomcat 7.
Locate the Class load problem. You can add the JVM parameter-XX: + TraceClassLoading-XX: + TraceClassUnloading at Tomcat startup.

Copyright Disclaimer: This article is an original article by the blogger and cannot be reproduced without the permission of the blogger.

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.