I am trying to connect to my tomcat server with jconsole via jmxmp protocol. I put jmxremote_optional.jar
everywhere in jdk and jre folders, but when I try to connect I still get:
malformed exception: unsupported protocol
How can I enable this protocol? Thanks a lot!
You also need to make sure that the JVM arguments have JMX enabled. The following arguments to the JVM are required:
java \
-Dcom.sun.management.jmxremote \
-Dcom.sun.management.jmxremote.authenticate=false \
...
Here's a page on how to enable JMX using Tomcat.
Edit:
I believe that ultimately, this was a classpath issue. Here's a page which gives some examples about how to set the classpath when running jconsole. It is something like:
jconsole -J-Djava.class.path=$JAVA_HOME/lib/jconsole.jar:\
$JAVA_HOME/lib/tools.jar:\
$WLS_HOME/lib/wljmxclient.jar \
-J-Djmx.remote.protocol.provider.pkgs=weblogic.management.remote