Profile Image
kk

G1 GC high pause time

gc time to long at peak times


do you have any suggestions? thks

 

https://gceasy.io/my-gc-report.jsp?p=c2hhcmVkLzIwMjIvMDYvMTYvZ2MubG9nLjAuY3VycmVudC56aXAtLTctNTUtMA==&channel=WEB

  • g1gc

  • younggc

  • g1-evacuation-pause

  • g1reservepercent

  • concgcthreads

  • increasejvmheapsize

  • maxgcpausetime

  • applicationexperiencinghightrafficvolume

  • batchjobrunning

Please Sign In or to post your comment or answer

Profile Image

Ram Lakshmanan

Hello KK!

 

 Greetings. I reviewed your GC analysis report. Your Max GC pause time is only 320 ms. It's good GC pause time (unless you are building trading applications). However there is cluster of G1 Evacuation pause events around 11am on both June' 15 and June' 16. It could be quite possible your application is experiencing high traffic volume around 11am (may be some kind of Batch job is running around that time).  

 

 

 Your application is cumulatively spending 4.42 minutes in G1 Evacuation pause, as shown in the below table.

 

 

Tips to reduce G1 Evacuation pause

G1 Evacuation pause is triggered when copying live objects from one set of regions to another set of regions. When Young generation regions are only copied then Young GC is triggered. When both Young + Tenured regions are copied, Mixed GC is triggered..

Solution:


1. Evacuation failure might happen because of over tuning. So eliminate all the memory related properties and keep only min and max heap and a realistic pause time goal (i.e. Use only -Xms, -Xmx and a pause time goal -XX:MaxGCPauseMillis). Remove any additional heap sizing such as -Xmn, -XX:NewSize, -XX:MaxNewSize, -XX:SurvivorRatio, etc.

2. If the problem still persists then increase JVM heap size (i.e. -Xmx).

3. If you can't increase the heap size and if you notice that the marking cycle is not starting early enough to reclaim the old generation then reduce -XX:InitiatingHeapOccupancyPercent. The default value is 45%. Reducing the value will start the marking cycle earlier. On the other hand, if the marking cycle is starting early and not reclaiming, increase the -XX:InitiatingHeapOccupancyPercent threshold above the default value.

4. You can also increase the value of the '-XX:ConcGCThreads' argument to increase the number of parallel marking threads. Increasing the concurrent marking threads will make garbage collection run fast.

5. Increase the value of the '-XX:G1ReservePercent' argument. Default value is 10%. It means the G1 garbage collector will try to keep 10% of memory free always. When you try to increase this value, GC will be triggered earlier, preventing the Evacuation pauses. Note: G1 GC caps this value at 50%.

Profile Image

kk

I really appreciate it. thanks

Got something else on mind? Post Your Question

Not the answer you're looking for? Browse other questions tagged
  • g1gc

  • younggc

  • g1-evacuation-pause

  • g1reservepercent

  • concgcthreads

  • increasejvmheapsize

  • maxgcpausetime

  • applicationexperiencinghightrafficvolume

  • batchjobrunning