问题
anybody work on Remote Monitoring in java (JMX). I have to monitor Remote Tomcat instance on Linux system and i need to monitor on local window machine. i am accessing Remote Tomcat using Putty through VPN. Please help..
I have tried by give jmx port in catalina.sh file of tomcat with variable JAVA_OPT and further tunneling in Putty ,but i m not able to access via localhost with port , also by using service jmx command. please help !!!
Thanks for your time and support in advance ..
回答1:
Remote JMX needs two ports to operate properly. And the second one (the RMI registry port) is by default picked randomly causing problems with firewalls etc.
Since JDK7u4 you can use
-Dcom.sun.management.jmxremote.rmi.port=<port>
to set the RMI port to be used.
See this blog for more detailed steps.
来源:https://stackoverflow.com/questions/19442719/remote-jmx-technology