VisualVM issue when starting JMX agent with jcmd

Martin Traverso mtraverso at gmail.com
Thu Aug 29 23:36:53 PDT 2013


I'm running into an issue when connecting to a process from VisualVM.
First, let me describe the setup:
- A Linux machine running jstatd configured with a "grant all permissions"
policy file and a test java program that sleeps forever. The Java version
is:

   java version "1.7.0_10"
   Java(TM) SE Runtime Environment (build 1.7.0_10-b18)
   Java HotSpot(TM) 64-Bit Server VM (build 23.6-b04, mixed mode)

- VisualVM 1.3.6 (Java 1.7.0_25-b15) running on a Mac, with a "jstatd
connection" entry for the first machine

If I start the test program with the following -D options and connect to it
in VisualVM, everything works fine. I can see the Overview, Monitor,
Threads, MBeans tabs, browse the mbeans, etc.

   -Dcom.sun.management.jmxremote=true
   -Dcom.sun.management.jmxremote.port=9600
   -Dcom.sun.management.jmxremote.rmi.port=9601
   -Dcom.sun.management.jmxremote.authenticate=false
   -Dcom.sun.management.jmxremote.ssl=false

If, instead, I run it without any command line options and start the jmx
agent via jcmd, some tabs are missing when I connect to the process in
VisualVM. Also half of the things don't work (e.g., the mbeans tab shows
"Data not available because JMX connection to the JMX agent could not be
established", CPU information in the monitor tab is disabled, etc).

   jcmd <pid> ManagementAgent.start jmxremote.port=9600
jmxremote.rmi.port=9601 jmxremote.ssl=false jmxremote.authenticate=false
   jcmd <pid> ManagementAgent.start_local

Is this expected behavior? Is there any way around it? Maybe I'm missing
some configuration options…

Thanks!

Martin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.openjdk.java.net/pipermail/serviceability-dev/attachments/20130829/b37161c7/attachment.html 


More information about the serviceability-dev mailing list