无法连接到RMI注册表 [英] Failed to connect to RMI registry
问题描述
我正在Ubuntu 12.04上运行activemq-5.9,可以说我是主动MQ的新手。
I am running activemq-5.9 on Ubuntu 12.04 and it would be fair to say that I am new to active MQ.
我怀疑我正在排队记录和而不是让它们出队,因此我正在研究使用JMX连接到我的活动MQ代理,并查看发生了什么。 Jconsole失败。
I suspect that I am queueing records and not de-queueing them, so I am looking into using JMX to connect to my active MQ broker and see what's going on. Jconsole fails.
这很困难,因为有关如何执行此操作的大多数文档都已过时,但是我终于开始运行activemq列表了。当我这样做时,它会抛出一个相当长的堆栈跟踪:
This is hard because most of the docs on how to do this is old, but I finally get down to running activemq list. When I do, it throws a rather lengthy stacktrace:
Connecting to JMX URL: service:jmx:rmi:///jndi/rmi://localhost:1099/jmxrmi
ERROR: java.lang.RuntimeException: Failed to execute list task. Reason: java.io.IOException: Failed to retrieve RMIServer stub: javax.naming.ServiceUnavailableException [Root exception is java.rmi.ConnectException: Connection refused to host: localhost; nested exception is:
java.net.ConnectException: Connection refused]
...
Caused by: java.rmi.ConnectException: Connection refused to host: localhost; nested exception is:
java.net.ConnectException: Connection refused
at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:619)
at sun.rmi.transport.tcp.TCPChannel.createConnection(TCPChannel.java:216)
at sun.rmi.transport.tcp.TCPChannel.newConnection(TCPChannel.java:202)
at sun.rmi.server.UnicastRef.newCall(UnicastRef.java:342)
at sun.rmi.registry.RegistryImpl_Stub.lookup(Unknown Source)
at com.sun.jndi.rmi.registry.RegistryContext.lookup(RegistryContext.java:118)
... 21 more
Caused by: java.net.ConnectException: Connection refused
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:345)
at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)
at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)
at java.net.Socket.connect(Socket.java:589)
at java.net.Socket.connect(Socket.java:538)
at java.net.Socket.<init>(Socket.java:434)
at java.net.Socket.<init>(Socket.java:211)
at sun.rmi.transport.proxy.RMIDirectSocketFactory.createSocket(RMIDirectSocketFactory.java:40)
at sun.rmi.transport.proxy.RMIMasterSocketFactory.createSocket(RMIMasterSocketFactory.java:148)
at sun.rmi.transport.tcp.TCPEndpoint.newSocket(TCPEndpoint.java:613)
... 26 more
我配置错了什么?我没有防火墙规则。我想不到要寻找什么。
Is there still something I have configured wrong? I have no firewall rules. I can't think what else to look for.
推荐答案
这里没有无法检索RMI服务器存根。连接到RMI注册表失败。它可能根本无法运行,或者您正在寻找错误的主机或端口。
There is no 'failure to retrieve RMI server stub' here. There is a failure to connect to the RMI registry. Either it isn't running at all or you're looking in the wrong host, or port.
这篇关于无法连接到RMI注册表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!