Eclipse 内存分析器 - 尝试获取堆转储时出错
我正在尝试使用 Eclipse 内存分析器工具 (MAT) 获取堆转储。我正在运行 Weblogic 10.3 应用程序服务器。它是安装了 32 位 Java 的 Windows XP 操作系统。当我尝试使用 MAT 获取正在运行 Weblogic 的进程的堆转储时,出现以下错误:
Error creating heap dump. jmap exit code = 1
Exception in thread "main" java.io.IOException: Premature EOF
at sun.tools.attach.HotSpotVirtualMachine.readInt(HotSpotVirtualMachine.java:226)
at sun.tools.attach.WindowsVirtualMachine.execute(WindowsVirtualMachine.java:88)
at sun.tools.attach.HotSpotVirtualMachine.executeCommand(HotSpotVirtualMachine.java:195)
at sun.tools.attach.HotSpotVirtualMachine.dumpHeap(HotSpotVirtualMachine.java:162)
at sun.tools.jmap.JMap.dump(JMap.java:224)
at sun.tools.jmap.JMap.main(JMap.java:122)
Error creating heap dump. jmap exit code = 1
Exception in thread "main" java.io.IOException: Premature EOF
at sun.tools.attach.HotSpotVirtualMachine.readInt(HotSpotVirtualMachine.java:226)
at sun.tools.attach.WindowsVirtualMachine.execute(WindowsVirtualMachine.java:88)
at sun.tools.attach.HotSpotVirtualMachine.executeCommand(HotSpotVirtualMachine.java:195)
at sun.tools.attach.HotSpotVirtualMachine.dumpHeap(HotSpotVirtualMachine.java:162)
at sun.tools.jmap.JMap.dump(JMap.java:224)
at sun.tools.jmap.JMap.main(JMap.java:122)
感谢任何帮助。
谢谢, 席德
I am trying to acquire heap dump using the Eclipse Memory Analyzer Tool (MAT). I have Weblogic 10.3 app server running. It's a windows XP OS with 32 bit Java installed. When I try to acquire heap dump using MAT for the process that's running Weblogic, I am getting the following error:
Error creating heap dump. jmap exit code = 1
Exception in thread "main" java.io.IOException: Premature EOF
at sun.tools.attach.HotSpotVirtualMachine.readInt(HotSpotVirtualMachine.java:226)
at sun.tools.attach.WindowsVirtualMachine.execute(WindowsVirtualMachine.java:88)
at sun.tools.attach.HotSpotVirtualMachine.executeCommand(HotSpotVirtualMachine.java:195)
at sun.tools.attach.HotSpotVirtualMachine.dumpHeap(HotSpotVirtualMachine.java:162)
at sun.tools.jmap.JMap.dump(JMap.java:224)
at sun.tools.jmap.JMap.main(JMap.java:122)
Error creating heap dump. jmap exit code = 1
Exception in thread "main" java.io.IOException: Premature EOF
at sun.tools.attach.HotSpotVirtualMachine.readInt(HotSpotVirtualMachine.java:226)
at sun.tools.attach.WindowsVirtualMachine.execute(WindowsVirtualMachine.java:88)
at sun.tools.attach.HotSpotVirtualMachine.executeCommand(HotSpotVirtualMachine.java:195)
at sun.tools.attach.HotSpotVirtualMachine.dumpHeap(HotSpotVirtualMachine.java:162)
at sun.tools.jmap.JMap.dump(JMap.java:224)
at sun.tools.jmap.JMap.main(JMap.java:122)
Any help is appreciated.
Thanks,
Sid
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您可以尝试的一件事是使用 jmap 保存转储并在 MAT 中打开它。
使用
jps
获取进程ID(pid)。One thing you could try is using
jmap
to save the dump and open it in MAT.Use
jps
to get the process id (pid).我在 Windows 上遇到了同样的问题,我通过以管理员身份打开 cmd.exe 解决了。
I met the same problem on Windows, I solved by open
cmd.exe
as Administrator.