in discussion projects / jmxterm » How to do a "local connection" like VisualVM does?
I'm not sure how VisualVM works but listing JVM processes(started with same run as user) is supported in JDK(like in jps or jconsole). Jmxterm takes advantage of this feature and allows you to list pids or connect to a pid.
In Jmxterm, you may use jvms command to list all running JMV processes started with current user and use open command to open it. For example
$>jvms
5641 ( ) - jmxterm-1.0-alpha-3-uber.jar
20276 ( ) - org.eclipse.equinox.launcher_1.1.1.R36x_v20101122_1400.jar -os linux -ws gtk -arch x86 -showsplash -launcher /opt/local/eclipse/eclipse-java-helios-SR2-linux-gtk/eclipse -name Eclipse —launcher.library /opt/local/eclipse/eclipse-java-helios-SR2-linux-gtkplugins/org.eclipse.equinox.launcher.gtk.linux.x86_1.1.2.R36x_v20101019_1345/eclipse_1310.s -startup /opt/local/eclipse/eclipse-java-helios-SR2-linux-gtkplugins/org.eclipse.equinox.launcher_1.1.1.R36x_v20101122_1400.jar -exitdata 72800b -product org.eclipse.epp.package.java.product -vm /opt/local/sun/jdk1.7.0/bin/java -vmargs -Dosgi.requiredJavaVersion=1.5 -XX:MaxPermSize=256m -Xms40m -Xmx384m -jar /opt/local/eclipse/eclipse-java-helios-SR2-linux-gtk//plugins/org.eclipse.equinox.launcher_1.1.1.R36x_v20101122_1400.jar
$>open 5641
#Connection to 5641 is opened
$>domains
#following domains are available
JMImplementation
com.sun.management
java.lang
java.util.logging