Uploaded image for project: 'SonarQube'
  1. SonarQube
  2. SONAR-13559

Can't connect to JMX in Compute Engine

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 8.5
    • Component/s: Compute Engine
    • Labels:
      None
    • Edition:
      Community
    • Production Notes:
      None

      Description

      It's not possible to do a local connection to the JMX server of the Compute Engine.

      It is likely that the Security Manager that is configured in the CE is interfering with it.

       

      We should add an IT testing JMX for Web and CE processes.

       

       

      jconsole -debug shows the following:

      java.lang.SecurityException: attempt to add a Permission to a readonly Permissions objectjava.lang.SecurityException: attempt to add a Permission to a readonly Permissions object at java.base/java.security.Permissions.add(Permissions.java:128) at java.base/java.security.Policy$UnsupportedEmptyCollection.add(Policy.java:843) at java.rmi/sun.rmi.server.LoaderHandler.getLoaderAccessControlContext(LoaderHandler.java:1005) at java.rmi/sun.rmi.server.LoaderHandler.lookupLoader(LoaderHandler.java:881) at java.rmi/sun.rmi.server.LoaderHandler.loadClass(LoaderHandler.java:404) at java.rmi/sun.rmi.server.LoaderHandler.loadClass(LoaderHandler.java:186) at java.rmi/java.rmi.server.RMIClassLoader$2.loadClass(RMIClassLoader.java:637) at java.rmi/java.rmi.server.RMIClassLoader.loadClass(RMIClassLoader.java:264) at java.rmi/sun.rmi.server.MarshalInputStream.resolveClass(MarshalInputStream.java:213) at java.base/java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1886) at java.base/java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1772) at java.base/java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2060) at java.base/java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1594) at java.base/java.io.ObjectInputStream.readObject(ObjectInputStream.java:430) at java.rmi/sun.rmi.server.UnicastRef.unmarshalValue(UnicastRef.java:322) at java.rmi/sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:339) at java.rmi/sun.rmi.transport.Transport$1.run(Transport.java:200) at java.rmi/sun.rmi.transport.Transport$1.run(Transport.java:197) at java.base/java.security.AccessController.doPrivileged(Native Method) at java.rmi/sun.rmi.transport.Transport.serviceCall(Transport.java:196) at java.rmi/sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:562) at java.rmi/sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:796) at java.rmi/sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$0(TCPTransport.java:677) at java.base/java.security.AccessController.doPrivileged(Native Method) at java.rmi/sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:676) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) at java.base/java.lang.Thread.run(Thread.java:834) at java.rmi/sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:283) at java.rmi/sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:260) at java.rmi/sun.rmi.server.UnicastRef.invoke(UnicastRef.java:161) at jdk.remoteref/jdk.jmx.remote.internal.rmi.PRef.invoke(Unknown Source) at java.management.rmi/javax.management.remote.rmi.RMIConnectionImpl_Stub.isRegistered(Unknown Source) at java.management.rmi/javax.management.remote.rmi.RMIConnector$RemoteMBeanServerConnection.isRegistered(RMIConnector.java:865) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.base/java.lang.reflect.Method.invoke(Method.java:566) at jdk.jconsole/sun.tools.jconsole.ProxyClient$SnapshotInvocationHandler.invoke(ProxyClient.java:992) at jdk.proxy1/com.sun.proxy.jdk.proxy1.$Proxy0.isRegistered(Unknown Source) at jdk.jconsole/sun.tools.jconsole.ProxyClient.tryConnect(ProxyClient.java:380) at jdk.jconsole/sun.tools.jconsole.ProxyClient.connect(ProxyClient.java:313) at jdk.jconsole/sun.tools.jconsole.VMPanel$2.run(VMPanel.java:296) 

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              duarte.meneses Duarte Meneses
              Reporter:
              duarte.meneses Duarte Meneses
              Votes:
              5 Vote for this issue
              Watchers:
              6 Start watching this issue

                Dates

                Due:
                Created:
                Updated:
                Resolved: