File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Performance and the fly likes Garbage collection issue in old gen space Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Performance
Bookmark "Garbage collection issue in old gen space" Watch "Garbage collection issue in old gen space" New topic

Garbage collection issue in old gen space

Shenaz Assu
Ranch Hand

Joined: Sep 21, 2007
Posts: 32
Hi all,

We are doing a performance test on our application and after a particular stage the server is hanging and finally it dies. Please find the details below.

JDK: jdk_1.5 update 14
App server: jboss-4.0.5.GA
System Configuration: Sun Microsystems sun4v Sun Fire T200
System clock frequency: 200 MHz
Memory size: 4088 Megabytes
Processors: 24

We are using visualgc and jconsole to monitor jvm activities. From jconsole, we noticed that the old gen space is getting filled up and no gc is happening to free the old gen space and eventually the system dies. We verfied the same thing with visual gc as well. The jvm args we are using in our application is given below.

'-server -Xmx1024m -Xms1024m -XX:+DisableExplicitGC -XX:MaxPermSize=150m -XX:+UseParallelOldGC -XX:+UseParallelGC -Xss196k -XX:SurvivorRatio=8 -XX:TargetSurvivorRatio=90 -XX:MaxTenuringThreshold=31'

When old gen is getting filled up why no gc is happening? Is it because we are using parallelgc? How can be this solved? Please help us. We are stuck with this for weeks and need to be resolved urgently.

PFA the screen shot of visual gc.

All help are highly appreciated. Thanks a lot!!


[Thumbnail for parallelgc_visualgc.jpg]

Kees Jan Koster
JavaMonitor Support

Joined: Mar 31, 2009
Posts: 251
Dear Shenaz,

Have you tried taking a heap dump and analysing that with a dump processor like Yourkit? It looks like you have a memory leak -or- your app just needs that much memory. You are under a load test after all and JBoss is a real memory pig.

Also, if you suspect a GC problem, have you considered letting the JVM pick a GC instead? Is if this problem is GC related, it will go away when you pick a different GC, methinks.

Kees Jan

Java-monitor, JVM monitoring made easy <- right here on Java Ranch
Shenaz Assu
Ranch Hand

Joined: Sep 21, 2007
Posts: 32

Hi Kees Jan,

We tried the same setup with the below jvm args.

'-Xmx1024m -Xincgc -XX:MaxPermSize=256m'

In this case, the server survived but the GUI response was slow. This made us wonder if the problem is with gc because with incgc its surviving and with parallegc its not.

Is there any known stability issue while using parallelgc? Our understanding is that, for multiprocessor high memory servers, parallelgc is ideal. Then in this case why its not working?

Please correct me if I'm wrong.

Shenaz Assu
Ranch Hand

Joined: Sep 21, 2007
Posts: 32
One thing what we noticed while using parallelgc is that, even when the eden space and old gen space was full and despite the server hanging, we never got an OutOfMemory error.

Any idea why this was happening?
I agree. Here's the link:
subject: Garbage collection issue in old gen space
It's not a secret anymore!