Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Plain View
Kafka, mail # user - Re: Exception from kafka server 0.8


+
Chris Curtin 2013-04-24, 19:46
Copy link to this message
-
Re: Exception from kafka server 0.8
Jun Rao 2013-04-25, 03:52
Actually, replication factor 2 means a total of 2 replicas (a leader and a
follower). If the leader is down, another replica should automatically take
over as the leader. There could be some transient errors in the producer,
but they shouldn't last long.

Thanks,

Jun
On Wed, Apr 24, 2013 at 12:46 PM, Chris Curtin <[EMAIL PROTECTED]>wrote:

> I'm pretty sure a replication factor of 2 means leader and 2 slaves.
> Shutting down one means the 2 slaves requirement isn't met.
>
>
> On Wed, Apr 24, 2013 at 3:42 PM, Yu, Libo <[EMAIL PROTECTED]> wrote:
>
> > I figured out the scenario. I have three machines, one server on each of
> > them.
> > I created a topic with three partitions and replication factor 2. After
> > using the
> > Topic for some time, I shut down one server. When producer sent data to
> the
> > same topic, the error occurred. I still don't know what is the cause of
> it.
> >
> > Regards,
> >
> > Libo
> >
> > From: Yu, Libo [ICG-IT]
> > Sent: Wednesday, April 24, 2013 3:29 PM
> > To: '[EMAIL PROTECTED]'
> > Subject: Exception from kafka server 0.8
> >
> > I got this error while running produce performance test.
> >
> > This is from server:
> > [2013-04-24 15:23:19,082] ERROR Error while fetching metadata for
> > partition [test5,2] (kafka.admin.AdminUtils$)
> > kafka.common.ReplicaNotAvailableException
> >         at kafka.admin.AdminUtils$$anonfun$3.apply(AdminUtils.scala:228)
> >         at kafka.admin.AdminUtils$$anonfun$3.apply(AdminUtils.scala:201)
> >         at
> >
> scala.collection.TraversableLike$$anonfun$map$1.apply(TraversableLike.scala:206)
> >         at
> >
> scala.collection.TraversableLike$$anonfun$map$1.apply(TraversableLike.scala:206)
> >         at
> >
> scala.collection.LinearSeqOptimized$class.foreach(LinearSeqOptimized.scala:61)
> >         at scala.collection.immutable.List.foreach(List.scala:45)
> >         at
> > scala.collection.TraversableLike$class.map(TraversableLike.scala:206)
> >         at scala.collection.immutable.List.map(List.scala:45)
> >         at
> >
> kafka.admin.AdminUtils$.kafka$admin$AdminUtils$$fetchTopicMetadataFromZk(AdminUtils.scala:201)
> >         at
> >
> kafka.admin.AdminUtils$$anonfun$fetchTopicMetadataFromZk$1.apply(AdminUtils.scala:194)
> >         at
> >
> kafka.admin.AdminUtils$$anonfun$fetchTopicMetadataFromZk$1.apply(AdminUtils.scala:194)
> >         at
> >
> scala.collection.TraversableLike$$anonfun$map$1.apply(TraversableLike.scala:206)
> >         at scala.collection.immutable.Set$Set1.foreach(Set.scala:81)
> >         at
> > scala.collection.TraversableLike$class.map(TraversableLike.scala:206)
> >         at scala.collection.immutable.Set$Set1.map(Set.scala:68)
> >         at
> > kafka.admin.AdminUtils$.fetchTopicMetadataFromZk(AdminUtils.scala:194)
> >         at
> > kafka.server.KafkaApis.handleTopicMetadataRequest(KafkaApis.scala:463)
> >         at kafka.server.KafkaApis.handle(KafkaApis.scala:67)
> >         at
> > kafka.server.KafkaRequestHandler.run(KafkaRequestHandler.scala:41)
> >         at java.lang.Thread.run(Thread.java:722)
> >
> > This is from producer:
> > [2013-04-24 15:23:28,297] WARN Failed to send producer request with
> > correlation id 5531 to broker 2 with data for partitions [test5,0]
> > (kafka.producer.async.DefaultEventHandler)
> > java.net.SocketTimeoutException
> >         at
> > sun.nio.ch.SocketAdaptor$SocketInputStream.read(SocketAdaptor.java:226)
> >         at
> sun.nio.ch.ChannelInputStream.read(ChannelInputStream.java:103)
> >         at
> >
> java.nio.channels.Channels$ReadableByteChannelImpl.read(Channels.java:385)
> >         at kafka.utils.Utils$.read(Utils.scala:374)
> >         at
> >
> kafka.network.BoundedByteBufferReceive.readFrom(BoundedByteBufferReceive.scala:54)
> >         at
> > kafka.network.Receive$class.readCompletely(Transmission.scala:56)
> >         at
> >
> kafka.network.BoundedByteBufferReceive.readCompletely(BoundedByteBufferReceive.scala:29)
> >         at
> kafka.network.BlockingChannel.receive(BlockingChannel.scala:100)