jmap可以生成java應(yīng)用程序的堆快照和對(duì)象的統(tǒng)計(jì)信息
jmap -histo 2892 >/tmp/2892.txt
jmap可得到應(yīng)用程序的當(dāng)前堆快照
[bigdata@iZuf6j6c7vo33i9lxbvqjaZ ~]$ jmap -dump:format=b,file=/tmp/2892.hprof 2892
Dumping heap to /tmp/2892.hprof ...
Heap dump file created