This discussion is archived
1 2 3 Previous Next 35 Replies Latest reply: Feb 10, 2012 1:58 AM by Klara Ward, Java Mission Control Dev Go to original post RSS
  • 15. Re: how to connect JROCKIT mission control to remote weblogic server??
    Hirt Guru Moderator
    Currently Being Moderated
    There you go. They are not on the same subnet. If you trace the route the packets must travel, you will probably find that they would need to pass several routers in between. The default TTL for the packets is 0 - they will not live past the first router. In your case I'd skip JDP and go for just creating a connection in JRockit Mission Control manually.

    Kind regards,
    Marcus
  • 16. Re: how to connect JROCKIT mission control to remote weblogic server??
    751846 Newbie
    Currently Being Moderated
    Hi Marcus,

    Thanks a lot for helping me out here and clarifying my doubts.

    Again, coming back to exception above, we do not need below option while connecting to server locally:
    -J-Xbootclasspath
    Does it mean that this JAR file is present in server's classpath?

    Thanks & Regards,
    Sanjeev
  • 17. Re: how to connect JROCKIT mission control to remote weblogic server??
    Hirt Guru Moderator
    Currently Being Moderated
    Hi Sanjeev,

    Are you saying that local connections to the Server works, and remote ones does not? And by local connections, do you mean connecting with JRockit Mission Control through an automatically discovered JVM under "Local" in the JVM Browser tree?

    Kind regards,
    Marcus
  • 18. Re: how to connect JROCKIT mission control to remote weblogic server??
    751846 Newbie
    Currently Being Moderated
    Hi Marcus,

    By local I mean, running from same box where weblogic is installed. It will come under Local.

    Thanks,
    Sanjeev
  • 19. Re: how to connect JROCKIT mission control to remote weblogic server??
    Hirt Guru Moderator
    Currently Being Moderated
    And you tried the local connection after a remote connection had already failed once?

    Kind regards,
    Marcus
  • 20. Re: how to connect JROCKIT mission control to remote weblogic server??
    Hirt Guru Moderator
    Currently Being Moderated
    I'll try to explain:

    You have a JVM running your application. Let's call it A. In A there is an MBean server allowing clients talking to it using an RMI based protocol (JMXRMI). Now, the application running in A has decided that the ordinary MBean info class in the SDK is not sufficient so a new one has been invented, let's call that class vignettesomething.MBeanInfo.

    Let's say a client connects to A over JMXRMI. Let's call the client C. C asks for metadata about the MBeans in A, and A happily starts sending instances of vignettesomething.MBeanInfo. Now, C has no idea about what a vignettsomething.MBeanInfo is, so when C starts to unmarshall them an exception is thrown (since C by default is not allowed to download the class definition from A).

    So there are a few ways to fix this:
    1. Make sure that C also knows about vignettesomething.MBeanInfo, i.e. put it on the classpath of the client.
    2. Make sure that C is allowed to download the class vignettesomething.MBeanInfo from A. This means setting the policy for C to allow this (Google java.security.policy, and remember that you will need to use the -J-D syntax for setting system properties using the JRMC launcher).
    3. Make sure that the application in A uses standard OpenMBean classes and the standard MBeanInfo class.

    Hope this helps!

    Kind regards,
    Marcus
  • 21. Re: how to connect JROCKIT mission control to remote weblogic server??
    751846 Newbie
    Currently Being Moderated
    Hi Marcus,

    Thanks a lot for your information. This is indeed very helpful. Now, let me try to explina my issue:-

    There is a Server A (Windows 2003 32-bit) on which Weblogic 10 is installed. I set autodiscovery=true and ran JRMC from JROCKIT\bin folder. Now, it is showing two JVMs on that server itself:-
    1. Under Discovered > JDP : This is giving above exception which running Console.
    2. Under Discovered > LOCAL : This is working fine.

    Could you please put your comments on above? I checked and JAVA classpath is set to JROCKIT only.

    Thanks,
    Sanjeev
  • 22. Re: how to connect JROCKIT mission control to remote weblogic server??
    Hirt Guru Moderator
    Currently Being Moderated
    Hi Sanjeev,

    This is quite interesting. If nothing differs other than you performing a local vs. remote connections, I'd say that local connections do away with the security manager demand for allowing RMI class loading. To me, that sounds quite strange, but perhaps this is the case.

    In a previous post you said it did work for "a while" even when using remote connections. To me that sounds like an application being deployed after a while, doing funky things. Just to make sure I understand precisely what you are saying:

    1. Does remote connections work at all? In other words, is it a period of time (perhaps startup?) where remote connections actually do work?
    2. Does it always work with local connections even when remote ones are no longer working?

    Kind regards,
    Marcus
  • 23. Re: how to connect JROCKIT mission control to remote weblogic server??
    Hirt Guru Moderator
    Currently Being Moderated
    Sanjeev,

    Are you an Oracle employee or an Oracle customer? If so, I could provide you with a custom build of R27.6.5 containing the fix from 4.0.1 that ignores MBeans having these kinds of problems (CL#130628, if you find yourself talking to JRockit SE directly). E-mail me at marcus dot hirt at oracle dot com.

    Kind regards,
    Marcus
  • 24. Re: how to connect JROCKIT mission control to remote weblogic server??
    751846 Newbie
    Currently Being Moderated
    Hi Marcus,

    Thanks a lot for helping me here.

    Solution to above issue is that either upgrade to JRMC 4.0 or do a patch as below:-
    1. Download jrmx.jar from https://www.hirt.se/cgi-bin/twiki/viewfile/Main/JRockitMissionControl?rev=1;filename=rjmx.jar
    2. Copying the rjmx.jar file over JROCKIT_HOME/missioncontrol/plug-ins/com.jrockit.mc.rjmx_3.1.0.*/rjmx.jar.

    Note that the patch will cause JRMC to ignore the MBeans having marshalling problems. To properly solve it so that the marshalling problem goes away, the RMI classloading, or classpath, must still be fixed.

    Thanks & Regards,
    Sanjeev
  • 25. Re: how to connect JROCKIT mission control to remote weblogic server??
    user161771 - oracle Expert
    Currently Being Moderated
    I received a strange error like this too and got around it using the 4.0.1 plugins with JDP turned on. When I used the local server it gave me the CNFE, but when I used the JDP listing in the JRMC perspective, it went through without an issue.
    !ENTRY org.eclipse.core.jobs 4 2 2010-09-13 14:56:14.323
    !MESSAGE An internal error occurred during: "Open [LocalConnectionDescriptor [PID=7196]] in Flight Recorder Control View".
    !STACK 0
    java.lang.ExceptionInInitializerError
         at javax.management.remote.rmi.RMIConnector.findRMIServerJRMP(RMIConnector.java:1944)
         at javax.management.remote.rmi.RMIConnector.findRMIServer(RMIConnector.java:1858)
         at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:257)
         at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:227)
         at com.jrockit.mc.rjmx.internal.RJMXConnection.connect(RJMXConnection.java:643)
         at com.jrockit.mc.rjmx.internal.RJMXConnection.establishConnection(RJMXConnection.java:609)
         at com.jrockit.mc.rjmx.internal.RJMXConnection.setupServer(RJMXConnection.java:582)
         at com.jrockit.mc.rjmx.internal.RJMXConnection.connect(RJMXConnection.java:159)
         at com.jrockit.mc.rjmx.internal.RJMXConnectorModel.establishConnection(RJMXConnectorModel.java:129)
         at com.jrockit.mc.rjmx.internal.RJMXConnectorModel.connect(RJMXConnectorModel.java:172)
         at com.jrockit.mc.rjmx.ConnectionManager.innerConnect(ConnectionManager.java:95)
         at com.jrockit.mc.rjmx.ConnectionManager.connect(ConnectionManager.java:61)
         at com.jrockit.mc.flightrecorder.controlpanel.ui.model.JvmRepository.add(JvmRepository.java:258)
         at com.jrockit.mc.flightrecorder.controlpanel.ui.model.JvmRepository.addOrReconnect(JvmRepository.java:165)
         at com.jrockit.mc.flightrecorder.controlpanel.ui.model.JvmRepository.add(JvmRepository.java:127)
         at com.jrockit.mc.flightrecorder.controlpanel.ui.jobs.ConnectionDescriptorJob.addDescriptorsToJvmRepository(ConnectionDescriptorJob.java:47)
         at com.jrockit.mc.flightrecorder.controlpanel.ui.jobs.OpenFlightRecorderJob.run(OpenFlightRecorderJob.java:29)
         at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
    Caused by: org.omg.CORBA.INITIALIZE: Cannot instantiate weblogic.iiop.PortableRemoteObjectDelegateImpl  vmcid: 0x0  minor code: 0  completed: No
         at javax.rmi.PortableRemoteObject.createDelegateIfSpecified(PortableRemoteObject.java:184)
         at javax.rmi.PortableRemoteObject.<clinit>(PortableRemoteObject.java:61)
         ... 18 more
    Caused by: java.lang.ClassNotFoundException: weblogic.iiop.PortableRemoteObjectDelegateImpl (no security manager: RMI class loader disabled)
         at sun.rmi.server.LoaderHandler.loadClass(LoaderHandler.java:375)
         at sun.rmi.server.LoaderHandler.loadClass(LoaderHandler.java:165)
         at java.rmi.server.RMIClassLoader$2.loadClass(RMIClassLoader.java:620)
         at java.rmi.server.RMIClassLoader.loadClass(RMIClassLoader.java:202)
         at java.rmi.server.RMIClassLoader.loadClass(RMIClassLoader.java:135)
         at javax.rmi.PortableRemoteObject.loadDelegateClass(PortableRemoteObject.java:205)
         at javax.rmi.PortableRemoteObject.createDelegateIfSpecified(PortableRemoteObject.java:182)
         at javax.rmi.PortableRemoteObject.<clinit>(PortableRemoteObject.java:61)
         at javax.management.remote.rmi.RMIConnector.findRMIServerJRMP(RMIConnector.java:1944)
         at javax.management.remote.rmi.RMIConnector.findRMIServer(RMIConnector.java:1858)
         at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:257)
         at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:228)
         at com.jrockit.mc.rjmx.internal.RJMXConnection.connect(RJMXConnection.java:644)
         at com.jrockit.mc.rjmx.internal.RJMXConnection.establishConnection(RJMXConnection.java:609)
         at com.jrockit.mc.rjmx.internal.RJMXConnection.setupServer(RJMXConnection.java:582)
         at com.jrockit.mc.rjmx.internal.RJMXConnection.connect(RJMXConnection.java:160)
         at com.jrockit.mc.rjmx.internal.RJMXConnectorModel.establishConnection(RJMXConnectorModel.java:129)
         at com.jrockit.mc.rjmx.internal.RJMXConnectorModel.connect(RJMXConnectorModel.java:173)
         ... 8 more
  • 26. Re: how to connect JROCKIT mission control to remote weblogic server??
    851566 Newbie
    Currently Being Moderated
    Hi all,

    I'm getting a connection timed out exception when trying to connect to a remote wls. The connection to remote wls must be established via ssh (putty with appropriate tunnel config). I tested it with telnet and it works but with jrmc it fails.

    Any hints?

    Kind regards,

    Michael
  • 27. Re: how to connect JROCKIT mission control to remote weblogic server??
    Klara Ward, Java Mission Control Dev Explorer
    Currently Being Moderated
    Are you using JRockit R28?

    What is the error message you get?
  • 28. Re: how to connect JROCKIT mission control to remote weblogic server??
    851566 Newbie
    Currently Being Moderated
    Hi,

    Local (Windows box): jrockit-jdk1.6.0_26-R28.1.4-4.0.1
    Remote (Linux box): jrockit_160_05_R27.6.2-20
    Exception is:
    Could not open Management Console for 127.0.0.1:xxxx.
    com.jrockit.mc.rjmx.ConnectionException: Connection refused to host: x.x.x.x; nested exception is:
         java.net.ConnectException: Connection timed out: connect
    com.jrockit.mc.rjmx.ConnectionException: Connection refused to host: x.x.x.x; nested exception is:
         java.net.ConnectException: Connection timed out: connect
         at com.jrockit.mc.rjmx.ConnectionManager.connect(ConnectionManager.java:63)
         at com.jrockit.mc.console.ui.actions.StartConsole$1.preConnect(StartConsole.java:39)
         at com.jrockit.mc.browser.utils.PreConnectJob.run(PreConnectJob.java:74)
         at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
    Caused by: java.rmi.ConnectException: Connection refused to host: x.x.x.x; nested exception is:
         java.net.ConnectException: Connection timed out: connect
         at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:601)
         at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:198)
         at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:184)
         at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:110)
         at javax.management.remote.rmi.RMIServerImpl_Stub.newClient(Unknown Source)
         at javax.management.remote.rmi.RMIConnector.getConnection(RMIConnector.java:2329)
         at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:279)
         at javax.management.remote.rmi.RMIConnector.connect(RMIConnector.java:228)
         at com.jrockit.mc.rjmx.internal.RJMXConnection.connect(RJMXConnection.java:644)
         at com.jrockit.mc.rjmx.internal.RJMXConnection.establishConnection(RJMXConnection.java:609)
         at com.jrockit.mc.rjmx.internal.RJMXConnection.setupServer(RJMXConnection.java:582)
         at com.jrockit.mc.rjmx.internal.RJMXConnection.connect(RJMXConnection.java:160)
         at com.jrockit.mc.rjmx.internal.RJMXConnectorModel.establishConnection(RJMXConnectorModel.java:129)
         at com.jrockit.mc.rjmx.internal.RJMXConnectorModel.connect(RJMXConnectorModel.java:173)
         at com.jrockit.mc.rjmx.ConnectionManager.innerConnect(ConnectionManager.java:95)
         at com.jrockit.mc.rjmx.ConnectionManager.connect(ConnectionManager.java:61)
         ... 3 more

    Kind regards,

    Michael
  • 29. Re: how to connect JROCKIT mission control to remote weblogic server??
    Klara Ward, Java Mission Control Dev Explorer
    Currently Being Moderated
    Remote needs to be R28 as well,
    R27 will use different ports the rmi registry (default 7091) and the rmi server (random port, can't really configure tunnel)
    R28 uses the same port be default.

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points