我只是解开了rieman 0.2.5 tarball并且运行了
bin / riemann etc / riemann.config
Ruby版本:ruby 1.8.5(2006-08-25)[x86_64-linux]
Java版“1.6.0_11”
红帽企业Linux客户端版本5.3(Tikanga)
我收到以下错误:
ERROR [2014-11-21 12:52:43,395] main - riemann.bin - Couldn't start
java.util.concurrent.ExecutionException: org.jboss.netty.channel.ChannelException: Failed to bind to: /127.0.0.1:5555
at java.util.concurrent.FutureTask$Sync.innerGet(FutureTask.java:222)
at java.util.concurrent.FutureTask.get(FutureTask.java:83)
at clojure.core$deref_future.invoke(core.clj:2180)
at clojure.core$future_call$reify__6320.deref(core.clj:6420)
at clojure.core$deref.invoke(core.clj:2200)
at clojure.core$pmap$step__6333$fn__6335.invoke(core.clj:6470)
at clojure.lang.LazySeq.sval(LazySeq.java:40)
at clojure.lang.LazySeq.seq(LazySeq.java:49)
at clojure.lang.RT.seq(RT.java:484)
at clojure.core$seq.invoke(core.clj:133)
at clojure.core$dorun.invoke(core.clj:2855)
at riemann.core$transition_BANG_.invoke(core.clj:156)
at clojure.lang.Atom.swap(Atom.java:51)
at clojure.core$swap_BANG_.invoke(core.clj:2233)
at riemann.config$apply_BANG_.invoke(config.clj:268)
at riemann.bin$_main.doInvoke(bin.clj:63)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at riemann.bin.main(Unknown Source)
Caused by: org.jboss.netty.channel.ChannelException: Failed to bind to: /127.0.0.1:5555
at org.jboss.netty.bootstrap.ConnectionlessBootstrap.bind(ConnectionlessBootstrap.java:204)
at riemann.transport.udp.UDPServer.start_BANG_(udp.clj:92)
at riemann.service$fn__8682$G__8676__8684.invoke(service.clj:20)
at riemann.service$fn__8682$G__8675__8687.invoke(service.clj:20)
at clojure.core$pmap$fn__6328$fn__6329.invoke(core.clj:6466)
at clojure.core$binding_conveyor_fn$fn__4145.invoke(core.clj:1910)
at clojure.lang.AFn.call(AFn.java:18)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.net.BindException: Address already in use
at sun.nio.ch.Net.bind(Native Method)
at sun.nio.ch.DatagramChannelImpl.bind(DatagramChannelImpl.java:495)
at sun.nio.ch.DatagramSocketAdaptor.bind(DatagramSocketAdaptor.java:80)
at org.jboss.netty.channel.socket.nio.NioDatagramPipelineSink.bind(NioDatagramPipelineSink.java:129)
at org.jboss.netty.channel.socket.nio.NioDatagramPipelineSink.eventSunk(NioDatagramPipelineSink.java:77)
at org.jboss.netty.handler.execution.ExecutionHandler.handleDownstream(ExecutionHandler.java:186)
at org.jboss.netty.handler.codec.oneone.OneToOneEncoder.handleDownstream(OneToOneEncoder.java:54)
at org.jboss.netty.channel.Channels.bind(Channels.java:561)
at org.jboss.netty.channel.AbstractChannel.bind(AbstractChannel.java:189)
at org.jboss.netty.bootstrap.ConnectionlessBootstrap.bind(ConnectionlessBootstrap.java:198)
... 11 more
WARN [2014-11-21 12:52:43,395] pool-1-thread-1 - riemann.transport.udp - UDP handler caught
java.net.BindException: Address already in use
at sun.nio.ch.Net.bind(Native Method)
at sun.nio.ch.DatagramChannelImpl.bind(DatagramChannelImpl.java:495)
at sun.nio.ch.DatagramSocketAdaptor.bind(DatagramSocketAdaptor.java:80)
at org.jboss.netty.channel.socket.nio.NioDatagramPipelineSink.bind(NioDatagramPipelineSink.java:129)
at org.jboss.netty.channel.socket.nio.NioDatagramPipelineSink.eventSunk(NioDatagramPipelineSink.java:77)
at org.jboss.netty.handler.execution.ExecutionHandler.handleDownstream(ExecutionHandler.java:186)
at org.jboss.netty.handler.codec.oneone.OneToOneEncoder.handleDownstream(OneToOneEncoder.java:54)
at org.jboss.netty.channel.Channels.bind(Channels.java:561)
at org.jboss.netty.channel.AbstractChannel.bind(AbstractChannel.java:189)
at org.jboss.netty.bootstrap.ConnectionlessBootstrap.bind(ConnectionlessBootstrap.java:198)
at riemann.transport.udp.UDPServer.start_BANG_(udp.clj:92)
at riemann.service$fn__8682$G__8676__8684.invoke(service.clj:20)
at riemann.service$fn__8682$G__8675__8687.invoke(service.clj:20)
at clojure.core$pmap$fn__6328$fn__6329.invoke(core.clj:6466)
at clojure.core$binding_conveyor_fn$fn__4145.invoke(core.clj:1910)
at clojure.lang.AFn.call(AFn.java:18)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
任何想法??
答案 0 :(得分:1)
错误似乎表明端口5555已在使用中。也许先前(中止)的开始留下了一个仍然有端口处理的进程?
执行netstat -ao
(Windows)或netstat -ap
(Linux)以查看是否已有侦听端口5555,以及哪个进程有句柄,然后终止该进程。
答案 1 :(得分:0)
我遇到了同样的情况。
您可以打开终端并输入
sudo netstat -nap | grep 5555
将会显示如下:
tcp6 0 0 127.0.0.1:5555 ::: * LISTEN 11465 / java
udp6 0 0 127.0.0.1:5555 ::: * 2863 / java
您可以在终端中输入
ps aux | grep 11465
并杀死进程。
在大多数情况下,导致此错误的原因是您打开了两个相同的服务。
您可以运行此命令来检查服务状态:
sudo service riemann status
启动黎曼:
sudo service riemann start
并结束服务:
sudo service rimann stop