我已经从4.0升级到GlassFish 4.1,现在我无法从JConsole和VisualVM访问它(但是我曾经)。 JConsole在input用户名/密码之前输出:
java.io.IOException: Failed to retrieve RMIServer stub: javax.naming.CommunicationException [Root exception is java.rmi.ConnectIOException: non-JRMP server at remote endpoint] at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:369) at javax.management.remote.JMXConnectorFactory.connect(JMXConnectorFactory.java:268) at sun.tools.jconsole.ProxyClient.tryConnect(ProxyClient.java:357) at sun.tools.jconsole.ProxyClient.connect(ProxyClient.java:313) at sun.tools.jconsole.VMPanel$2.run(VMPanel.java:292) Caused by: javax.naming.CommunicationException [Root exception is java.rmi.ConnectIOException: non-JRMP server at remote endpoint] at com.sun.jndi.rmi.registry.RegistryContext.lookup(RegistryContext.java:118) at com.sun.jndi.toolkit.url.GenericURLContext.lookup(GenericURLContext.java:203) at javax.naming.InitialContext.lookup(InitialContext.java:411) at javax.management.remote.rmi.RMIConnector.findRMIServerJNDI(RMIConnector.java:1936) at javax.management.remote.rmi.RMIConnector.findRMIServer(RMIConnector.java:1903) at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:286) ... 4 more Caused by: java.rmi.ConnectIOException: non-JRMP server at remote endpoint at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:248) at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:202) at sun.rmi.server.UnicastRef.newCall(UnicastRef.java:341) at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source) at com.sun.jndi.rmi.registry.RegistryContext.lookup(RegistryContext.java:114) ... 9 more
我在Glassfish的日志中有这个行:
JMXStartupService has started JMXConnector on JMXService URL service:jmx:rmi://Debian-70-wheezy-64-minimal:8686/jndi/rmi://Debian-70-wheezy-64-minimal:8686/jmxrmi
我可以使用telnet连接。 我怎么解决这个问题?