java.rmi.NoSuchObjectException: no such object in table
2014-02-12 01:40
399 查看
jmx链接的时候,最简单的例子都行不通,郁闷,出现了:
参考:http://reiz6153.blog.163.com/blog/static/401089152009442723208/
代码:
MBeanServer mbs = MBeanServerFactory.createMBeanServer("HelloAgent");
JMXServiceURL url = new JMXServiceURL( "service:jmx:rmi://localhost:9092/jndi/rmi://localhost:9092/jmxrmi");
Map<String, ?> map = new HashMap<String, String>();
JMXConnectorServer connector = JMXConnectorServerFactory.newJMXConnectorServer(url, map , mbs);
ObjectName connectorName = new ObjectName("JMXBookAgent:name=RMIConnector");
mbs.registerMBean(connector, connectorName);
connector.start();
异常:
二月 12, 2014 1:34:33 上午 sun.rmi.transport.Transport serviceCall
FINE: RMI TCP Connection(1)-127.0.0.1: [127.0.0.1] exception:
java.rmi.NoSuchObjectException: no such object in table at sun.rmi.transport.Transport.serviceCall(Transport.java:153) at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:553) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:808) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:667) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) at java.lang.Thread.run(Thread.java:722)
java.io.IOException: Cannot bind to URL [rmi://localhost:9092/jmxrmi]: javax.naming.CommunicationException [Root exception is java.rmi.NoSuchObjectException: no such object in table] at javax.management.remote.rmi.RMIConnectorServer.newIOException(RMIConnectorServer.java:827) at javax.management.remote.rmi.RMIConnectorServer.start(RMIConnectorServer.java:432) at jmx.HelloAgent.<init>(HelloAgent.java:51) at jmx.HelloAgent.main(HelloAgent.java:65) Caused by: javax.naming.CommunicationException [Root exception is java.rmi.NoSuchObjectException: no such object in table] at com.sun.jndi.rmi.registry.RegistryContext.bind(RegistryContext.java:143) at com.sun.jndi.toolkit.url.GenericURLContext.bind(GenericURLContext.java:226) at javax.naming.InitialContext.bind(InitialContext.java:419) at javax.management.remote.rmi.RMIConnectorServer.bind(RMIConnectorServer.java:644) at javax.management.remote.rmi.RMIConnectorServer.start(RMIConnectorServer.java:427) ... 2 more Caused by: java.rmi.NoSuchObjectException: no such object in table at sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:273) at sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:251) at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:377) at sun.rmi.registry.RegistryImpl_Stub.bind(Unknown Source) at com.sun.jndi.rmi.registry.RegistryContext.bind(RegistryContext.java:137) ... 6 more
网上搜索许久还是不行。。。
http://www.myexception.cn/j2se/java.rmi.NoSuchObjectException.html
http://blog.csdn.net/pengchang_1981/article/details/8069124 弱想关
http://stackoverflow.com/questions/645208/java-rmi-nosuchobjectexception-no-such-object-in-table 看得晕。。。
待续。。。
参考:http://reiz6153.blog.163.com/blog/static/401089152009442723208/
代码:
MBeanServer mbs = MBeanServerFactory.createMBeanServer("HelloAgent");
JMXServiceURL url = new JMXServiceURL( "service:jmx:rmi://localhost:9092/jndi/rmi://localhost:9092/jmxrmi");
Map<String, ?> map = new HashMap<String, String>();
JMXConnectorServer connector = JMXConnectorServerFactory.newJMXConnectorServer(url, map , mbs);
ObjectName connectorName = new ObjectName("JMXBookAgent:name=RMIConnector");
mbs.registerMBean(connector, connectorName);
connector.start();
异常:
二月 12, 2014 1:34:33 上午 sun.rmi.transport.Transport serviceCall
FINE: RMI TCP Connection(1)-127.0.0.1: [127.0.0.1] exception:
java.rmi.NoSuchObjectException: no such object in table at sun.rmi.transport.Transport.serviceCall(Transport.java:153) at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:553) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:808) at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:667) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) at java.lang.Thread.run(Thread.java:722)
java.io.IOException: Cannot bind to URL [rmi://localhost:9092/jmxrmi]: javax.naming.CommunicationException [Root exception is java.rmi.NoSuchObjectException: no such object in table] at javax.management.remote.rmi.RMIConnectorServer.newIOException(RMIConnectorServer.java:827) at javax.management.remote.rmi.RMIConnectorServer.start(RMIConnectorServer.java:432) at jmx.HelloAgent.<init>(HelloAgent.java:51) at jmx.HelloAgent.main(HelloAgent.java:65) Caused by: javax.naming.CommunicationException [Root exception is java.rmi.NoSuchObjectException: no such object in table] at com.sun.jndi.rmi.registry.RegistryContext.bind(RegistryContext.java:143) at com.sun.jndi.toolkit.url.GenericURLContext.bind(GenericURLContext.java:226) at javax.naming.InitialContext.bind(InitialContext.java:419) at javax.management.remote.rmi.RMIConnectorServer.bind(RMIConnectorServer.java:644) at javax.management.remote.rmi.RMIConnectorServer.start(RMIConnectorServer.java:427) ... 2 more Caused by: java.rmi.NoSuchObjectException: no such object in table at sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:273) at sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:251) at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:377) at sun.rmi.registry.RegistryImpl_Stub.bind(Unknown Source) at com.sun.jndi.rmi.registry.RegistryContext.bind(RegistryContext.java:137) ... 6 more
网上搜索许久还是不行。。。
http://www.myexception.cn/j2se/java.rmi.NoSuchObjectException.html
http://blog.csdn.net/pengchang_1981/article/details/8069124 弱想关
http://stackoverflow.com/questions/645208/java-rmi-nosuchobjectexception-no-such-object-in-table 看得晕。。。
待续。。。
相关文章推荐
- java.rmi.NoSuchObjectException: no such object in table
- java.rmi.NoSuchObjectException: no such object in table异常问题解析
- Spring RMI java.rmi.NoSuchObjectException: no such object in table
- 奋斗了n(n>7)小时,终于解决了连接远程JMS JNDI的问题:java.rmi.NoSuchObjectException: no such object in table
- 连接远程JMS JNDI的问题:java.rmi.NoSuchObjectException
- RMI no such object in table异常
- NoSuchObjectException exception in RMI
- 解决:Redis:java.util.NoSuchElementException: Unable to validate object at
- [解决方法]org.dbunit.dataset.NoSuchTableException: Did not find table 'tab1' in schema 'null'
- elasticsearch 报出 Exception in thread "main" java.lang.NoSuchFieldError: LUCENE_3_6
- java.util.NoSuchElementException: Timeout waiting for idle object
- Exception in thread "main" java.lang.NoSuchFieldError: INSTANCE
- java.util.NoSuchElementException: Timeout waiting for idle object
- java中Exception in thread "main" java.util.NoSuchElementException
- Exception in thread "main" java.lang.NoSuchFieldError: level
- NoSuchObjectException(message:default.simple table not found) 问题解决【SOLVED】
- java.util.NoSuchElementException: Timeout waiting for idle object
- Exception in thread "main" java.util.NoSuchElementException
- Exception in thread "main" java.lang.NoSuchFieldError的 一种解决办法
- JAVA Scanner 用法注意事项(scanner 使用错误:Exception in thread "main" java.util.NoSuchElementExceptionation )