There is a frequent occurence of FULL GC in our system. We are using Java application running on Tomcat server. Our application is running using internal load balancer setup. We are seeing lot of Full GC's in the server logs due to which the application is hung and Proxy errors are occured.

The Java parameter values we are using are: Webapp wrapper: wrapper.java.additional.4=-Xms382M wrapper.java.additional.5=-Xmx1024M Backapp wrapper: wrapper.java.additional.4=-Xms382M wrapper.java.additional.5=-Xmx1024M

The error found in webapp wrapper logs: INFO | jvm 1 | 2010/11/26 09:33:19 | [PSYoungGen: 1398460K->140291K(1514624K)] 4623364K->3491394K(5009920K), 0.7285303 secs] [Times: user=1.42 sys=0.00, real=0.72 secs] INFO | jvm 1 | 2010/11/26 09:33:19 | 68539.126: [Full GC DEBUG | wrapperp | 2010/11/26 09:33:19 | send a packet PING : ping

Tried to change the JVM values to increase the heap size. But of no use. I suspect that there could be some other reason other than these parameters which is causing the issue.

Can anyone please help me on this?

  • 1
    While it may just not have enough memory, usually this manifests are as an increasing frequency of full GCs - not multiple consecutive full GCs. I'd recommend dumping the heap when it starts going into repeated full gc then having a look with jprobe or similar – symcbean Nov 26 '10 at 10:20
  • Provide the output of: jmap -heap <vmid> – HTTP500 Jan 6 '11 at 22:50

Add this parameter in your setDomainEnv.sh: -XX:+DisableExplicitGC

Restart your servers. This will avoid any explicit GCs that may be called by the application and allow the JVM to decide internally and trigger the Full GC where it is really needed.


Add this to your java_opts: "-XX:+UseConcMarkSweepGC" This is a multi threaded GC that works much better under high load.

  • Hi,Thanks for your inputs. We are testing this and will let you know if it is working. – Viji Dec 2 '10 at 10:59
  • Hi...This even doesn't work. :( – Viji Dec 2 '10 at 11:17

Full GC is an important event in the garbage collection process. During this full GC phase, garbage is collected from all the regions in the JVM heap (Young, Old, Perm, Metaspace). Full GC tends to evict more objects from memory, as it runs across all generations. A Full GC event has multiple phases. Certain phases of the Full GC event (like ‘initial-mark, ‘remark’, ‘cleanup’,..) pauses all the application threads that are running the JVM. During this period, no customer transactions will be processed. JVM will use all the CPU cycles to perform garbage collection. Due to that CPU consumption will be quite high. Thus in general full GCs aren’t desired. Needless to ask the desirability of consecutive full GCs. Consecutive full GCs will cause following problems:

  1. CPU consumption will spike up.
  2. Because JVM is paused, the response time of your application transactions will degrade. Thus it will impact your SLAs and cause poor customer experience.

Eliminate consecutive Full GC's

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.