Post

java常用命令

目录:

jvm常用

  • 导出线程快照:jstack 进程id
  • dump出堆栈: jmap -dump:format=b,file=文件名.hprof <进程ID>
  • 打印GC信息(每1s一次,共4次): jstat -gc 进程id 1000 4
  • 打印GC信息,百分比(每1s一次,共4次)jstat -gcutil 进程id 1000 4
This post is licensed under CC BY 4.0 by the author.