您好,欢迎来到伴沃教育。
搜索
您的当前位置:首页GC overhead limit exceeded

GC overhead limit exceeded

来源:伴沃教育

错误:java.lang.OutOfMemoryError: GC overhead limit exceeded

What is causing it?

The java.lang.OutOfMemoryError: GC overhead limit exceeded error is the JVM’s way of signalling that your application spends too much time doing garbage collection with too little result. By default the JVM is configured to throw this error if it spends more than 98% of the total time doing GC and when after the GC only less than 2% of the heap is recovered。

也就是说GC试图回收内存,但是什么也没有回收到。默认情况下,JVM花费了98%的时间在GC上,但是GC过之后只有不到2%的堆内存被回收。

What would happen if this GC overhead limit would not exist?

简单来讲,就是一次GC过后,并没有回收到内存,很快又会进行GC,极端情况下会循环GC(关键是并没有回收到可用内存),从而导致CPU 100%负载。

Copyright © 2019- bangwoyixia.com 版权所有 湘ICP备2023022004号-2

违法及侵权请联系:TEL:199 1889 7713 E-MAIL:2724546146@qq.com

本站由北京市万商天勤律师事务所王兴未律师提供法律服务