我们的服务有一个完整的GC。这是自服务启动以来第一个完整的GC。 当完整的GC发生时,旧内存中仍有足够的可用内存。 所以我想知道它是如何发生的,以及如何解决它。
2017-03-09T08:27:18.757+0800: 80101.423: [GC 80101.423: [ParNew: 441137K->22010K(471872K), 0.0133050 secs] 1090097K->670970K(2044736K), 0.0134350 secs] [Times: user=0.07 sys=0.00, real=0.02 secs]
2017-03-09T08:28:43.053+0800: 80185.720: [GC 80185.720: [ParNew: 441466K->22372K(471872K), 0.0146790 secs] 1090426K->671332K(2044736K), 0.0148100 secs] [Times: user=0.07 sys=0.00, real=0.01 secs]
2017-03-09T08:29:01.133+0800: 80203.799: [Full GC 80203.799: [CMS (concurrent mode failure)[YG occupancy: 122632 K (471872 K)]80204.163: [weak refs processing, 0.0011100 secs]80204.164: [scrub string table, 0.0017900 secs]: 648959K->313273K(1572864K), 0.5230930 secs] 771592K->435905K(2044736K), [CMS Perm : 136619K->136619K(136832K)], 0.5233420 secs] [Times: user=0.84 sys=0.00, real=0.53 secs]
2017-03-09T08:30:06.668+0800: 80269.334: [GC 80269.335: [ParNew: 441828K->18343K(471872K), 0.0164870 secs] 755102K->331616K(2044736K), 0.0166300 secs] [Times: user=0.08 sys=0.00, real=0.01 secs]
2017-03-09T08:31:52.787+0800: 80375.454: [GC 80375.454: [ParNew: 437799K->21566K(471872K), 0.0137290 secs] 751072K->334840K(2044736K), 0.0138540 secs] [Times: user=0.07 sys=0.00, real=0.02 secs]
java版本:1.7.0_25,64位
-Xmn512M
-Xmx2048M
-Xms2048M
-XX:MaxPermSize=256M
-XX:PermSize=128M
-XX:SurvivorRatio=8
-XX:+UseConcMarkSweepGC
-XX:CMSFullGCsBeforeCompaction=50
-XX:+UseCMSCompactAtFullCollection
-XX:+DisableExplicitGC
-XX:MaxTenuringThreshold=30
-verbose:gc
-XX:+PrintGCDetails
-XX:+PrintGCTimeStamps
-XX:+PrintGCDateStamps
-XX:+PrintFlagsFinal