We are trying to get an HP UX server up for running some Batch Jobs in Java. The problem in the nutshell is this:
These Batch Jobs are running on the Jeus Application Server (a Made in Korea product). Although most of the jobs are running on time, some Batch Jobs have reported the famous PermGen Out of Memory Error. We got a heap dump and started looking at the JVM options. They are as follows: Xms - 2048m Xmx - 2048m PermSize - 512m MaxPermSize - 512m. The old GC collector is CMS and the young generation collector is a Parallel Collector.
We noticed that the actual Heap size is quite fine and that the PErm Gen ran out of all its 512m of memory. HPJmeter showed that this was a gradual rise in the memory and hence, we suspected a memory leak. We looked at all the Class Loaders and there were about 168 instances of the core Jeus App Server ClassLoader. The memory leak estimator showed that the this Class Loader was leaking memory. It showed that the number of bytes held were only around 3MB.
We looked at the number of classes/types loaded by this class loader and there were around 512 items. The memory leak also showed some other objects as being involved in memory leaks.
I have the following questions:
- Now that the Classloader which is leaking has been identified, how do we identify the exact reference(s) which is causing the problem?
- If one class loader with a specific object id is shown as leaking memory, is it possible that the other instances of the same class loader leak the some varying amount of memory?
- Any guidance as to what to do next would be highly appreciated.
Aditya.