手动更改 Glassfish domain.xml 以解决调试错误
我在domain.xml 中有这行代码:
<java-config classpath-suffix="" debug-enabled="false" debug-options="-Xdebug -Xrunjdwp:transport=dt_socket,server=n,suspend=y,address=9009" env-classpath-ignored="true" java-home="${com.sun.aas.javaRoot}" javac-options="-g" rmic-options="-iiop -poa -alwaysgenerate -keepgenerated -g" system-classpath="">
如果我启动域,则不会出现错误。但是我想获得调试功能,所以我像这样更改了这部分:
debug-enabled="true"
当我想启动域时,它给出错误:
FATAL ERROR in native method: JDWP No transports initialized, jvmtiError=AGENT_ERROR_TRANSPORT_INIT(197)
ERROR: transport error 202: connect failed: Connection refused
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [../../../src/share/back/debugInit.c:690]
可能是什么问题?
I have this line of code at domain.xml:
<java-config classpath-suffix="" debug-enabled="false" debug-options="-Xdebug -Xrunjdwp:transport=dt_socket,server=n,suspend=y,address=9009" env-classpath-ignored="true" java-home="${com.sun.aas.javaRoot}" javac-options="-g" rmic-options="-iiop -poa -alwaysgenerate -keepgenerated -g" system-classpath="">
If I start the domain there is no error. However I want to get debug feature so I changed this part like this:
debug-enabled="true"
When I want to start the domain it gives error:
FATAL ERROR in native method: JDWP No transports initialized, jvmtiError=AGENT_ERROR_TRANSPORT_INIT(197)
ERROR: transport error 202: connect failed: Connection refused
ERROR: JDWP Transport dt_socket failed to initialize, TRANSPORT_INIT(510)
JDWP exit error AGENT_ERROR_TRANSPORT_INIT(197): No transports initialized [../../../src/share/back/debugInit.c:690]
What may be the problem?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
将
-Xrunjdwp:transport=dt_socket,server=n,suspend=y,address=9009
更改为
-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=9009
Change
-Xrunjdwp:transport=dt_socket,server=n,suspend=y,address=9009
to
-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=9009
Glassfish 3.0.1 中有许多domain.xml 文件。您必须确保修改与您的域名相对应的域名,例如:
Within Glassfish 3.0.1 there are many domain.xml files. You must be sure to modify the one corresponding to your domain like: