geronimo-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Janko Heilgeist <>
Subject PermGen space issues
Date Wed, 18 Feb 2009 14:21:07 GMT

I am currently debugging an EAR that isn't correctly undeployed. I
noticed in jconsole that the classes loaded during deployment are never
GCed after undeployment. Playing around with jmap and jhat I discovered
two places where IMHO something's amiss in Geronimo. I've never done
this kind of debugging before so please tell me if I am wrong ;-)

The first issue is in the component geronimo-transaction:

Java Local Reference (from
exclude  :
(164 bytes) (field inheritedAccessControlContext:) exclude
--> (41 bytes) (field
context:) exclude
--> [;@0x2aaab094c8f8 (144 bytes)
(Element 12 of [;@0x2aaab094c8f8:) exclude
--> (50 bytes) (field
classloader:) exclude
(156 bytes) exclude

A similar problem came up in the JBoss forum with an IdleRemover thread:

>From what I've pieced together from this and other sources, it looks to
me like the CurrentTime thread should be started in a privileged block
to prevent it from inheriting the AccessControlContext of my EAR. I've
attached a patch that works for me but YMMV.

The second issue is with the Tomcat parts of Geronimo and was not able
to completely debug this one:

--> org.apache.geronimo.tomcat.realm.TomcatJAASRealm@0x2aaab10ab438 (180
bytes)  (field container:) exclude
--> org.apache.geronimo.tomcat.GeronimoStandardContext@0x2aaab322d390
(749 bytes) (field parentClassLoader:) exclude
(156 bytes) (field parents:) exclude
--> [Ljava.lang.ClassLoader;@0x2aaab0b97958 (88 bytes) (Element 1 of
[Ljava.lang.ClassLoader;@0x2aaab0b97958:) exclude
(115 bytes) (field parent:) exclude
(156 bytes) exclude

Here, the last MultiParentClassLoader corresponds to the EAR and the one
in the middle belongs to the WAR inside the EAR. The
GeronimoStandardContext belongs to the WAR, too. It look to me like the
bi-directional reference between the TomcatJAASRealm and the
GeronimoStandardContext keeps the EAR's classloader from being GCed.

Any hints on what I can do to exactly locate this issue?


View raw message