JVM内存调优


总是报OOM问题:


jmap -heap 18384 >1.txt




using thread-local object allocation.
Parallel GC with 13 thread(s)


Heap Configuration:
MinHeapFreeRatio = 40
MaxHeapFreeRatio = 70
MaxHeapSize = 3221225472 (3072.0MB)
NewSize = 1073741824 (1024.0MB)
MaxNewSize = 1073741824 (1024.0MB)
OldSize = 4194304 (4.0MB)
NewRatio = 2
SurvivorRatio = 8
PermSize = 16777216 (16.0MB)
MaxPermSize = 67108864 (64.0MB)
G1HeapRegionSize = 0 (0.0MB)


Heap Usage:
PS Young Generation
Eden Space:
capacity = 805306368 (768.0MB)
used = 502500216 (479.22154998779297MB)
free = 302806152 (288.77845001220703MB)
62.39863932132721% used
From Space:
capacity = 134217728 (128.0MB)
used = 0 (0.0MB)
free = 134217728 (128.0MB)
0.0% used
To Space:
capacity = 134217728 (128.0MB)
used = 0 (0.0MB)
free = 134217728 (128.0MB)
0.0% used
PS Old Generation
capacity = 4194304 (4.0MB)
used = 0 (0.0MB)
free = 4194304 (4.0MB)
0.0% used
PS Perm Generation
capacity = 16777216 (16.0MB)
used = 11499056 (10.966354370117188MB)
free = 5278160 (5.0336456298828125MB)
68.53971481323242% used


7654 interned Strings occupying 614224 bytes.



两次上述操作对比后发现Eden SPace 利用率高,增加-Xmn1024m 同时增大堆内存 -Xmx3072, 即可。

你可能感兴趣的:(jvm内存)