无法远程连接到JMX? [英] Unable to remotely connect to JMX?

查看:69
本文介绍了无法远程连接到JMX?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

出于某些奇怪的原因,我无法使用 VisualVM jconsole 连接到JMX.

For some weird reason I am not able to connect using VisualVM or jconsole to a JMX.

用于启动要监视的VM的参数:

The parameters used to start the VM to be monitored:

-Dcom.sun.management.jmxremote.authenticate = false -Dcom.sun.management.jmxremote.ssl = false -Dcom.sun.management.jmxremote.port = 1100

我检查了一下,可以从本地和远程远程登录到此端口.

I checked, and I can telnet to this port, from both locally and remotely.

在花费大量时间尝试后,VisualVM或jconsole仍然无法连接.

Still, VisualVM or jconsole are failing to connect, after spending some considerably time trying to.

REMOTE MACHINE with JMX (debian)
java version "1.6.0_33"
Java(TM) SE Runtime Environment (build 1.6.0_33-b03-424-11M3720)
Java HotSpot(TM) 64-Bit Server VM (build 20.8-b03-424, mixed mode)

MY WORKSTATION (OS X)
java version "1.6.0_26"
Java(TM) SE Runtime Environment (build 1.6.0_26-b03)
Java HotSpot(TM) 64-Bit Server VM (build 20.1-b02, mixed mode)

出什么问题了?

推荐答案

添加 -Djava.rmi.server.hostname = host ip .甚至我也遇到了同样的问题,这确实解决了问题.

Add -Djava.rmi.server.hostname = host ip. Even i faced the same problem and this did the trick.

添加此 -Djava.rmi.server.hostname = host ip 会强制RMI服务使用主机ip而不是127.0.0.1

Addition of this -Djava.rmi.server.hostname = host ip forces RMI service to use the host ip instead of 127.0.0.1

这篇关于无法远程连接到JMX?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆