KeeperErrorCode = NoNode for /brokers/topics/test_topic/partitions

2017-03-25 21:55:55   作者:MangoCool   来源:MangoCool

 启动storm程序,报错:KeeperErrorCode = NoNode for /brokers/topics/ggsn_test_topic/partitions

详细信息:

ERROR backtype.storm.util - Async loop died!
java.lang.RuntimeException: java.lang.RuntimeException: org.apache.zookeeper.KeeperException$NoNodeException: KeeperErrorCode = NoNode for /brokers/topics/test_topic/partitions
        at storm.kafka.DynamicBrokersReader.getBrokerInfo(DynamicBrokersReader.java:81) ~[kafkaStorm-1.0-SNAPSHOT.jar:na]
        at storm.kafka.trident.ZkBrokerReader.<init>(ZkBrokerReader.java:42) ~[kafkaStorm-1.0-SNAPSHOT.jar:na]
        at storm.kafka.KafkaUtils.makeBrokerReader(KafkaUtils.java:57) ~[kafkaStorm-1.0-SNAPSHOT.jar:na]
        at storm.kafka.KafkaSpout.open(KafkaSpout.java:87) ~[kafkaStorm-1.0-SNAPSHOT.jar:na]
        at backtype.storm.daemon.executor$fn__3371$fn__3386.invoke(executor.clj:529) ~[kafkaStorm-1.0-SNAPSHOT.jar:na]
        at backtype.storm.util$async_loop$fn__460.invoke(util.clj:461) ~[kafkaStorm-1.0-SNAPSHOT.jar:na]
        at clojure.lang.AFn.run(AFn.java:24) [kafkaStorm-1.0-SNAPSHOT.jar:na]
        at java.lang.Thread.run(Thread.java:744) [na:1.7.0_45]
Caused by: java.lang.RuntimeException: org.apache.zookeeper.KeeperException$NoNodeException: KeeperErrorCode = NoNode for /brokers/topics/test_topic/partitions
        at storm.kafka.DynamicBrokersReader.getNumPartitions(DynamicBrokersReader.java:94) ~[kafkaStorm-1.0-SNAPSHOT.jar:na]
        at storm.kafka.DynamicBrokersReader.getBrokerInfo(DynamicBrokersReader.java:65) ~[kafkaStorm-1.0-SNAPSHOT.jar:na]
        ... 7 common frames omitted

从报错信息看,就是zookeeper目录下缺少对应的topic

解决办法:

手动创建该topic

./bin/kafka-topics.sh --create --topic test_topic --zookeeper localhost:2181 --partitions 3 --replication-factor 3

标签: storm error

分享:

上一篇idea提交storm任务,集群运行

下一篇Kafka简单应用示例

关于我

一个喜欢唱歌,热衷旅行,爱好电子产品的码农。没事,跟三五好友吼上几嗓子,约上几个背着行囊去露营或者宅在家里抱着孩子敲代码。

座右铭:当你的才华还撑不起你的野心的时候,你就应该静下心来学习,永不止步!

            人生之旅历途甚长,所争决不在一年半月,万不可因此着急失望,招精神之萎葸。


Copyright 芒果酷(mangocool.com) All rights reserved. 湘ICP备14019394号

免责声明:本网站部分文章转载其他媒体,意在为公众提供免费服务。如有信息侵犯了您的权益,可与本网站联系,本网站将尽快予以撤除。