-
Bug
-
Resolution: Fixed
-
P3
-
5.0, 6
-
None
-
b53
-
generic, x86
-
generic, linux
On machines using DHCP, jconsole will fail to connect to applications launched by Java Web Start. The failure arises because the management agent cannot be started in the target VM. This error is "hard to see" at this time because jconsole's error reporting is temporarily broken. It issue can also be demonstrated by configurating the environment to use the DNS name service:
C:\> java -Dsun.net.spi.nameservice.provider.1="dns,sun" -Dcom.sun.management.jmxremote Application
Error: Exception thrown by the agent : java.net.MalformedURLException: Local host name unknown: java.net.UnknownHostException: foobar: DNS name not found [response code 3]
Error occurred during initialization of VM
java.lang.RuntimeException: Exception thrown by the agent
at sun.management.Agent.error(Agent.java:288)
at sun.management.Agent.error(Agent.java:279)
at sun.management.Agent.startAgent(Agent.java:136)
at sun.management.Agent.startAgent(Agent.java:224)
The issue is that the local JMX connector server is attempting to use the machine's local address. In DHCP environments the hostname might not be resolved in DNS so the creation of the JMXServiceURL fails. In general the local JMX connector server should be using the loopback address and there is no need to use the host address.
C:\> java -Dsun.net.spi.nameservice.provider.1="dns,sun" -Dcom.sun.management.jmxremote Application
Error: Exception thrown by the agent : java.net.MalformedURLException: Local host name unknown: java.net.UnknownHostException: foobar: DNS name not found [response code 3]
Error occurred during initialization of VM
java.lang.RuntimeException: Exception thrown by the agent
at sun.management.Agent.error(Agent.java:288)
at sun.management.Agent.error(Agent.java:279)
at sun.management.Agent.startAgent(Agent.java:136)
at sun.management.Agent.startAgent(Agent.java:224)
The issue is that the local JMX connector server is attempting to use the machine's local address. In DHCP environments the hostname might not be resolved in DNS so the creation of the JMXServiceURL fails. In general the local JMX connector server should be using the loopback address and there is no need to use the host address.
- duplicates
-
JDK-6432683 -Dcom.sun.management.jmxremote crashes VM
-
- Closed
-