简体   繁体   English

如何收集任何java进程的堆转储

[英]How to collect heap dumps of any java process

I am new to Heaps , can anyone suggest how can i take heap dump of any java process (like Jmeter). 我是Heaps的新手,任何人都可以建议我如何对任何java进程(如Jmeter)进行堆转储。 I read about jmap command , but i am not getting where and how to execute / write it (in eclipse or cmd). 我读到了关于jmap命令,但我没有得到执行/编写它的地方和方式(在eclipse或cmd中)。 It might be a very basic question but still suggestions are requested.Can i download jmap.exe and jhat.exe from any where? 这可能是一个非常基本的问题,但仍然需要建议。我可以从任何地方下载jmap.exe和jhat.exe吗? Thank You 谢谢

Here is the command: 这是命令:

<JDK_HOME>/jmap -F -dump:live,format=b,file=<file_name.hprof> <process_id>

You can mention the file location here in this command. 您可以在此命令中提及文件位置。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM