jmap - Does histo & heap operation bring overhead to jvm?
问题 As the title states, how much overhead does jmap -histo and jmap -heap bring to a jvm respectively? If a memory sensitive Java process is at the edge of OutOfMemory (e.g around 96% of heap is full, and can't be cleared by full gc), is it possible for one of the operations to bring the jvm to OutOfMemory? 回答1: jmap -histo and jmap -heap work differently: jmap -histo uses Dynamic Attach Mechanism, and jmap -heap works through HotSpot Serviceability Agent. The difference is described here.