[Mc4j-development] mc4j and mx4j in Linux
Brought to you by:
ghinkl
From: CRISTINA D. D. <cd...@ti...> - 2004-02-11 10:52:25
|
Hello all! I am quite new to JMX and I am trying to install MC4J using MX4J. I am having some problems that I do not know hoe to resolve, that is why I am writing to this list for help. I have installed MC4JBeta 1.2 Beta 3 and MX4J 1.1.1 over Sun JDK 1.4.2 on Debian Linux. I have put mx4j libraries into jre/lib/ext and I have run the console. When I try to create an MX4J connection I receive this exeception: javax.naming.CommunicationException [Root exception is java.rmi.UnmarshalException: error unmarshalling return; nested exception is:=20 =09java.lang.ClassNotFoundException: mx4j.tools.adaptor.rmi.RMIAdaptor_Stub] =09at com.sun.jndi.rmi.registry.RegistryContext.lookup(RegistryContext.java= :92) =09at com.sun.jndi.rmi.registry.RegistryContext.lookup(RegistryContext.java= :98) =09at javax.naming.InitialContext.lookup(InitialContext.java:347) =09at mx4j.connector.rmi.RMIConnector.connect(RMIConnector.java:110) =09at org.mc4j.console.connection.Mx4jConnectionNode.connect(Mx4jConnection= Node.java:73) =09at org.mc4j.console.connection.ReconnectAction.performAction(ReconnectAc= tion.java:40) =09at org.openide.util.actions.NodeAction$3.run(NodeAction.java:440) =09at org.openide.util.actions.CallableSystemAction$2.run(CallableSystemAct= ion.java:121) =09at org.openide.util.Task.run(Task.java:136) =09at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:330) =09at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java= :677) Caused by: java.rmi.UnmarshalException: error unmarshalling return; nested exception is:=20 =09java.lang.ClassNotFoundException: mx4j.tools.adaptor.rmi.RMIAdaptor_Stub =09at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source) =09at com.sun.jndi.rmi.registry.RegistryContext.lookup(RegistryContext.java= :88) =09... 10 more Caused by: java.lang.ClassNotFoundException: mx4j.tools.adaptor.rmi.RMIAdaptor_Stub =09at java.net.URLClassLoader$1.run(URLClassLoader.java:199) =09at java.security.AccessController.doPrivileged(Native Method) =09at java.net.URLClassLoader.findClass(URLClassLoader.java:187) =09at java.lang.ClassLoader.loadClass(ClassLoader.java:289) =09at java.lang.ClassLoader.loadClass(ClassLoader.java:235) =09at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302) =09at java.lang.Class.forName0(Native Method) =09at java.lang.Class.forName(Class.java:219) =09at sun.rmi.server.LoaderHandler.loadClass(LoaderHandler.java:430) =09at sun.rmi.server.LoaderHandler.loadClass(LoaderHandler.java:165) =09at java.rmi.server.RMIClassLoader$2.loadClass(RMIClassLoader.java:631) =09at java.rmi.server.RMIClassLoader.loadClass(RMIClassLoader.java:257) =09at sun.rmi.server.MarshalInputStream.resolveClass(MarshalInputStream.jav= a:200) =09at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:151= 3) =09at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1435) =09at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1= 626) =09at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1274) =09at java.io.ObjectInputStream.readObject(ObjectInputStream.java:324) [catch] ... 12 more =3D=3D> java.rmi.UnmarshalException: error unmarshalling return; nested exception is:=20 =09java.lang.ClassNotFoundException: mx4j.tools.adaptor.rmi.RMIAdaptor_Stub =09at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source) =09at com.sun.jndi.rmi.registry.RegistryContext.lookup(RegistryContext.java= :88) =09at com.sun.jndi.rmi.registry.RegistryContext.lookup(RegistryContext.java= :98) =09at javax.naming.InitialContext.lookup(InitialContext.java:347) =09at mx4j.connector.rmi.RMIConnector.connect(RMIConnector.java:110) =09at org.mc4j.console.connection.Mx4jConnectionNode.connect(Mx4jConnection= Node.java:73) =09at org.mc4j.console.connection.ReconnectAction.performAction(ReconnectAc= tion.java:40) =09at org.openide.util.actions.NodeAction$3.run(NodeAction.java:440) =09at org.openide.util.actions.CallableSystemAction$2.run(CallableSystemAct= ion.java:121) =09at org.openide.util.Task.run(Task.java:136) =09at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:330) =09at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java= :677) Caused by: java.lang.ClassNotFoundException: mx4j.tools.adaptor.rmi.RMIAdaptor_Stub =09at java.net.URLClassLoader$1.run(URLClassLoader.java:199) =09at java.security.AccessController.doPrivileged(Native Method) =09at java.net.URLClassLoader.findClass(URLClassLoader.java:187) =09at java.lang.ClassLoader.loadClass(ClassLoader.java:289) =09at java.lang.ClassLoader.loadClass(ClassLoader.java:235) =09at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302) =09at java.lang.Class.forName0(Native Method) =09at java.lang.Class.forName(Class.java:219) =09at sun.rmi.server.LoaderHandler.loadClass(LoaderHandler.java:430) =09at sun.rmi.server.LoaderHandler.loadClass(LoaderHandler.java:165) =09at java.rmi.server.RMIClassLoader$2.loadClass(RMIClassLoader.java:631) =09at java.rmi.server.RMIClassLoader.loadClass(RMIClassLoader.java:257) =09at sun.rmi.server.MarshalInputStream.resolveClass(MarshalInputStream.jav= a:200) =09at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:151= 3) =09at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1435) =09at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1= 626) =09at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1274) =09at java.io.ObjectInputStream.readObject(ObjectInputStream.java:324) [catch] ... 12 more I have look into MX4J 1.1.1 libraries (mx4j-tools.jar and mx4j-jmx.jar) but I did not found the class mx4j.tools.adaptor.rmi.RMIAdaptor_Stub. Instead there is a class called mx4j.adaptor.rmi.RMIAdaptor_Stub. So I suppose that is why it throws that exception. I have then download mx4j 2.0 Beta 1, but that class did not appear in any of its libraries. Instead, it appears in the sources. So I have downloaded and recompile mx4j 2.0 Beta 2 src and I have generate the libraries. I have put the libraries again in the jre/lib/ext and I have launch the console again. I try to create the connection again but now I receive this exception: ava.lang.ClassCastException =09at mx4j.connector.rmi.jrmp.JRMPConnector.narrow(JRMPConnector.java:28) =09at mx4j.connector.rmi.RMIConnector.connect(RMIConnector.java:112) =09at org.mc4j.console.connection.Mx4jConnectionNode.connect(Mx4jConnection= Node.java:73) =09at org.mc4j.console.connection.ReconnectAction.performAction(ReconnectAc= tion.java:40) =09at org.openide.util.actions.NodeAction$3.run(NodeAction.java:440) =09at org.openide.util.actions.CallableSystemAction$2.run(CallableSystemAct= ion.java:121) =09at org.openide.util.Task.run(Task.java:136) =09at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:330) [catch] at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java= :677) =20 So do you know which version of MX4J and which one of MC4J to make it works? Can you pass that versions to me? Is there any document explaining how to configure this? Can anybody help me? I am not register in the list, so please answer with copy to me. Thank you very much in advance Cristina D=EDaz |