What's output if you do the following?

bin/kafka-list-topic.sh --zookeeper server2:3181 --unavailable-partitions

Thanks,

Jun


On Mon, Jan 20, 2014 at 6:43 PM, linxpwww <linxp...@163.com> wrote:

>  1,first try to produce topici 'ximi' in server3 (kafka server)
> [root@server3 kafka_2.8.0-0.8.0]# bin/kafka-console-producer.sh
> --broker-list server3:9092 --topic ximi
>
> ximi gest
> [2014-01-18 10:57:04,250] WARN Error while fetching metadata
> [{TopicMetadata for topic ximi ->
> No partition metadata for topic ximi due to
> kafka.common.LeaderNotAvailableException}] for topic [ximi]: class
> kafka.common.LeaderNotAvailableException
> (kafka.producer.BrokerPartitionInfo)
> [2014-01-18 10:57:04,272] WARN Error while fetching metadata
> [{TopicMetadata for topic ximi ->
> No partition metadata for topic ximi due to
> kafka.common.LeaderNotAvailableException}] for topic [ximi]: class
> kafka.common.LeaderNotAvailableException
> (kafka.producer.BrokerPartitionInfo)
> [2014-01-18 10:57:04,273] ERROR Failed to collate messages by topic,
> partition due to: Failed to fetch topic metadata for topic: ximi
> (kafka.producer.async.DefaultEventHandler)
> test new me
> hello
> 2, Second try to consume...
> [root@server3 kafka_2.8.0-0.8.0]# bin/kafka-console-consumer.sh
> --zookeeper server3:3181 --topic ximi --from-beginning
>
> [2014-01-18 10:57:59,971] WARN
> [console-consumer-65386_server3-1390013879485-3f815f14], no brokers found
> when trying to rebalance. (kafka.consumer.ZookeeperConsumerConnector)
> 3, Third, surprisingly I can find the topic in kafka topic list.
> [root@server3 kafka_2.8.0-0.8.0]# bin/kafka-list-topic.sh --zookeeper
> server2:3181
>
> topic: test partition: 0 leader: 2 replicas: 2 isr: 2
> topic: ximi partition: 0 leader: 2 replicas: 2 isr: 2
> topic: xp partition: 0 leader: 2 replicas: 2 isr: 2

Reply via email to