Hello Nicholas, The log shows the controller cannot connect with one of the brokers due to "ava.net.ConnectException: Connection refused". Are all your brokers in the same cluster?
Guozhang On Mon, Oct 28, 2013 at 3:37 PM, Nicholas Tietz <nti...@gmail.com> wrote: > Hi everyone, > > I'm having some problems getting Kafka 0.8 running. (I'm running this on > Mac OS X 10.8 with the latest updates; Java version 1.6.0_51.) I followed > the instructions from the quickstart for 0.8, both from-source and > from-binary (cleaned up all related files each time). However, I am getting > an exception when I try to start the Kafka server. > > Below is the relevant output from the console output. I cut the beginning > and the end. The "INFO 0 successfully elected as leader", "ERROR while > electing [...]" and the exception recur until I terminate the process. > > Any help on this issue would be appreciated. > > Thanks, > Nicholas Tietz > > Relevant console output: > [...] > [2013-10-28 18:35:03,055] INFO zookeeper state changed (SyncConnected) > (org.I0Itec.zkclient.ZkClient) > [2013-10-28 18:35:03,093] INFO Registered broker 0 at path /brokers/ids/0 > with address coffeemachine:9092. (kafka.utils.ZkUtils$) > [2013-10-28 18:35:03,094] INFO [Kafka Server 0], Connecting to ZK: > localhost:2181 (kafka.server.KafkaServer) > [2013-10-28 18:35:03,145] INFO Will not load MX4J, mx4j-tools.jar is not in > the classpath (kafka.utils.Mx4jLoader$) > [2013-10-28 18:35:03,151] INFO 0 successfully elected as leader > (kafka.server.ZookeeperLeaderElector) > [2013-10-28 18:35:03,263] ERROR Error while electing or becoming leader on > broker 0 (kafka.server.ZookeeperLeaderElector) > java.net.ConnectException: Connection refused > at sun.nio.ch.Net.connect(Native Method) > at sun.nio.ch.SocketChannelImpl.connect(SocketChannelImpl.java:532) > at kafka.network.BlockingChannel.connect(BlockingChannel.scala:57) > at > > kafka.controller.ControllerChannelManager.kafka$controller$ControllerChannelManager$$addNewBroker(ControllerChannelManager.scala:84) > at > > kafka.controller.ControllerChannelManager$$anonfun$1.apply(ControllerChannelManager.scala:35) > at > > kafka.controller.ControllerChannelManager$$anonfun$1.apply(ControllerChannelManager.scala:35) > at scala.collection.immutable.Set$Set1.foreach(Set.scala:81) > at > > kafka.controller.ControllerChannelManager.<init>(ControllerChannelManager.scala:35) > at > > kafka.controller.KafkaController.startChannelManager(KafkaController.scala:503) > at > > kafka.controller.KafkaController.initializeControllerContext(KafkaController.scala:467) > at > > kafka.controller.KafkaController.onControllerFailover(KafkaController.scala:215) > at > > kafka.controller.KafkaController$$anonfun$1.apply$mcV$sp(KafkaController.scala:89) > at > kafka.server.ZookeeperLeaderElector.elect(ZookeeperLeaderElector.scala:53) > at > > kafka.server.ZookeeperLeaderElector.startup(ZookeeperLeaderElector.scala:43) > at kafka.controller.KafkaController.startup(KafkaController.scala:396) > at kafka.server.KafkaServer.startup(KafkaServer.scala:96) > at > kafka.server.KafkaServerStartable.startup(KafkaServerStartable.scala:34) > at kafka.Kafka$.main(Kafka.scala:46) > at kafka.Kafka.main(Kafka.scala) > [2013-10-28 18:35:03,267] INFO New leader is 0 > (kafka.server.ZookeeperLeaderElector$LeaderChangeListener) > [2013-10-28 18:35:03,273] INFO 0 successfully elected as leader > (kafka.server.ZookeeperLeaderElector) > [2013-10-28 18:35:03,276] INFO [Kafka Server 0], Started > (kafka.server.KafkaServer) > [2013-10-28 18:35:03,294] ERROR Error while electing or becoming leader on > broker 0 (kafka.server.ZookeeperLeaderElector) > java.net.ConnectException: Connection refused > [...] > -- -- Guozhang