Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-654

Irrecoverable error while trying to roll a segment that already exists

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Blocker
    • Resolution: Fixed
    • 0.8.0
    • None
    • None
    • None

    Description

      I tried setting up a 5 broker 0.8 cluster and sending messages to 100s of topics on it. For a couple of topic partitions, the produce requests never succeed since they fail on the leader with the following error -

      [2012-12-05 22:54:05,711] WARN [Kafka Log on Broker 2], Newly rolled segment file 0000000000000000000
      0.log already exists; deleting it first (kafka.log.Log)
      [2012-12-05 22:54:05,711] WARN [Kafka Log on Broker 2], Newly rolled segment file 0000000000000000000
      0.index already exists; deleting it first (kafka.log.Log)
      [2012-12-05 22:54:05,715] ERROR [ReplicaFetcherThread-1-0-on-broker-2], Error due to (kafka.server.R
      eplicaFetcherThread)
      kafka.common.KafkaException: Trying to roll a new log segment for topic partition NusWriteEvent-4 with start offset 0 while it already exsits
      at kafka.log.Log.rollToOffset(Log.scala:456)
      at kafka.log.Log.roll(Log.scala:434)
      at kafka.log.Log.maybeRoll(Log.scala:423)
      at kafka.log.Log.append(Log.scala:257)
      at kafka.server.ReplicaFetcherThread.processPartitionData(ReplicaFetcherThread.scala:51)
      at kafka.server.AbstractFetcherThread$$anonfun$doWork$5.apply(AbstractFetcherThread.scala:125)
      at kafka.server.AbstractFetcherThread$$anonfun$doWork$5.apply(AbstractFetcherThread.scala:108)
      at scala.collection.immutable.HashMap$HashMap1.foreach(HashMap.scala:125)
      at scala.collection.immutable.HashMap$HashTrieMap.foreach(HashMap.scala:344)
      at scala.collection.immutable.HashMap$HashTrieMap.foreach(HashMap.scala:344)
      at kafka.server.AbstractFetcherThread.doWork(AbstractFetcherThread.scala:108)
      at kafka.utils.ShutdownableThread.run(ShutdownableThread.scala:50)

      Attachments

        1. kafka-654-v1.patch
          0.9 kB
          Neha Narkhede

        Issue Links

          Activity

            People

              nehanarkhede Neha Narkhede
              nehanarkhede Neha Narkhede
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: