Answer the question
In order to leave comments, you need to log in
Java JVM monitoring over ssh?
Hello to all Khabrovites. The question arose: how do you monitor a remote JVM? I have an application running on a remote server. It can only be accessed via ssh. I can not figure out how to set up a tunnel so that I can monitor the JVM. Tried running jstatd on a remote server with a port and then running jvisualVm with the following properties:
-J-Dnetbeans.system_socks_proxy=localhost:portNumber -J-Djava.net.useSystemProxies=true
But jVisualVm doesn't see the remote JVM.
Maybe I'm doing something wrong.
I will be very grateful
Answer the question
In order to leave comments, you need to log in
maybe not enough jmx?
- the remote Java application is running on JDK 5 or higher and has been started with a specific port for remote management and security has been disabled (both authentication and encryption), eg
$ java -Dcom.sun.management.jmxremote.port= - Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false MyApp
I also had this problem before and managed to overcome it.
The whole point is that jmx uses 2 ports, you can set one through the "com.sun.management.jmxremote.port" property, but the second is chosen randomly. There is a workaround
on the
oracle blog , though you will have to restart tomcat with the suggested java agent.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question