aragozin/jvm-tools

sjk cannot connect to MBean server with adopt openjdk 11

rjtokenring opened this issue · 1 comments

While using Adopt OpenJDK 11 for the running workload, sjk cannot access MBean server. All jvm are started with sames user. If workload is executed with Oracle JRE 1.8, utility works. In both cases, jmap/jstack application can connect to target JVM (Java11 and 8)

This is the output running AppMain with Adopt OpenJDK 11.
c@localdev:/opt/c/sjk|⇒ java -jar sjk-plus-0.11.jar jps 4087 com.net.AppMain 6266 sjk-plus-0.11.jar jps c@localdev:/opt/c/sjk|⇒ java -jar sjk-plus-0.11.jar gc -p 4087 Failed to access MBean server: 4087

Instead, running AppMain with Oracle JRE 8, connection happens.

MBean server connected Collecting GC stats ...

OpenJDK pre-build image taken from https://adoptopenjdk.net/.
Tested on CentOS 7 and 6

This feature was broken for post-8 Java.
Fixed in 0.12 version.