Ubuntu 下jdk工具attach pid错误

1、错误代码:

Error attaching to process: sun.jvm.hotspot.debugger.DebuggerException: Can't attach to the process 

2、解决方法:

$ sudo vi /etc/sysctl.d/10-ptrace.conf
##edit the following line>
kernel.yama.ptrace_scope = 1
##to look like this>
kernel.yama.ptrace_scope = 0

##reboot your system.
 

3、参考:

http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=7050524

猜你喜欢

转载自kinglord2010.iteye.com/blog/1447371