Skip to content

Instantly share code, notes, and snippets.

@mieky
Created January 27, 2014 10:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mieky/8646454 to your computer and use it in GitHub Desktop.
Save mieky/8646454 to your computer and use it in GitHub Desktop.
jvisualvm over ssh
on the remote (Ubuntu) machine:
/etc/default/tomcat7
->
JAVA_OPTS = "-Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.port=1098"
sudo service tomcat7 restart
on the local machine:
ssh -v -D 10000 <remote-host>
jvisualvm -J-Xms1G -J-Xmx1G -cp:a target/classes
Preferences > Network
SOCKS proxy: localhost:10000
No Proxy hosts: (empty)
Local > Add JMX connection > localhost:1098
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment