[讨论] young gc时间很长的问题请教各位

sharpzdh 2021-06-17
我们的server是接受网络过来的请求,根据请求内容返回查询结果,最近偶尔出现ygc需要很长时间,有时候能够恢复,有时候很长时间不能恢复只有重启服务,请教各位,什么情况下ygc会耗时这么高

sharpzdh 2021-06-17
java参数如下

-Xms30G -Xmx30G -Xmn20g -server  -Xss256K -XX:SurvivorRatio=8 -XX:+PrintReferenceGC -XX:+UseConcMarkSweepGC -XX:+UseCMSCompactAtFullCollection -XX:CMSInitiatingOccupancyFraction=70 -XX:+CMSParallelRemarkEnabled -XX:SoftRefLRUPolicyMSPerMB=0 -XX:CMSMaxAbortablePrecleanTime=20 -XX:+PrintGCDetails -Xloggc:/export/Logs/jmq4-server/%t-gc.log -XX:-OmitStackTraceInFastThrow -XX:MaxDirectMemorySize=256G -DPreloadBufferPool.MaxMemory=70% -Dio.netty.maxDirectMemory=10737418240

sharpzdh 2021-06-17

gc日志如下

857132.438: [GC (Allocation Failure) 857132.438: [ParNew857151.989: [SoftReference, 0 refs, 0.0000832 secs]857151.989: [WeakReference, 3 refs, 0.0000126 secs]857151.989: [FinalReference, 22 refs, 0.0000593 secs]857151.989: [PhanatomReference, 0 refs, 0 refs, 0.0000108 secs]857151.989: [JNI Weak Reference, 0.0000218 secs]: 17088422K->364038K(18874368K), 19.5511944 secs] 23586165K->6861780K(29360128K), 19.5513863 secs] [Times: user=447.87 sys=0.23, real=19.55 secs]

Global site tag (gtag.js) - Google Analytics