Kohei Nozaki's blog 

Profiling remote JVM over SSH with VisualVM

Posted on Friday Feb 06, 2015 at 01:31PM in Technology

UPDATE October 2015: This procedure requires a VisualVM distribution that can be obtained from https://visualvm.java.net . At least, It will work with VisualVM 1.3.8. May doesn’t work with VisualVM which has been installed as a part of JDK distribution. I have experienced VisualVM which comes with JDK8u60 doesn’t work.

First I tried that creating a tunnel like ssh remote.example.org -L 19999:localhost:9999 and connecting VisualVM to localhost:19999, but it didn’t worked. intead, creating a socks tunnel like ssh remote.example.com -D 1080 and connecting VisualVM to localhost:9999 via socks proxy is worked. detailed procedure is following:

  1. Create ssh socks tunnel

  2. Set manual proxy in VisualVM’s preferences

  3. Right-click Local

  4. Add JMX connection

  5. Enter localhost:9999 to text box

  6. Click OK

  7. Double-click newly added JMX icon

Make sure that destination JVM has started with following system properties:



Thank you. I was able to connect with this method.

Posted by Başar Daldal on August 22, 2016 at 09:33 PM JST #

Leave a Comment

HTML Syntax: NOT allowed