You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@kafka.apache.org by Gur Aizenberg <gu...@gmail.com> on 2019/10/20 12:29:26 UTC

Kafka Broker not Starting

Hey guys,

I am having a problem starting my Kafka Broker - I am using Kafka 0.11.

When I try to start the broker I get the error:
Fatal error during KafkaServer startup. Prepare to shutdown
(kafka.server.KafkaServer)
java.lang.IllegalArgumentException: inconsistent range

I saw that there is a bug regarding this issue:
https://issues.apache.org/jira/browse/KAFKA-7401

Did anyone encounter this issue? Or knows how to fix this?
Any help would be appreciated!




Thank you,
Gur

Re: Kafka Broker not Starting

Posted by "M. Manna" <ma...@gmail.com>.
As long as you have >1 broker (2,3, whatever) and min insyc replica is set
to 1 (set by server.properties), you should be able to stop the affected
broker(s), delete all data files, and restart them.
It would recreate all the files based on your live leader.
Before you do that, please ensure that your healthy broker is in-sync for
all topic partition.

However, if you have only 1 broker and zookeeper (and you can handle loss
of data), you should just stop the broker,  delete (*Only*) kafka data
files, and restart the broker. It will take all the latest data from ZK and
recreate the files. This works __only__  if you are using zk to store
offsets and letting kafka coordinate consumer groups.

I have just verified the 2nd approach (with 1 broker and zk only, as I have
done it long time ago), and yes it recreates the data files for Kafka.

I hope this helps,
Thanks,

On Wed, 23 Oct 2019 at 13:35, Gur Aizenberg <gu...@gmail.com> wrote:

> Hey,
>
> Thank you for the reply.
>
> Unfortunately an upgrade is not possible for us on this environment.
>
> What would happen if I delete the broker files when RF < 3?
> Data loss is something we can handle in order to bring this back up.
>
> Currently we have a large number of under replicated partitions as well as
> occurrences of broker failures.
>
> Thank you for the help!
>
> On Sun, Oct 20, 2019 at 5:20 PM M. Manna <ma...@gmail.com> wrote:
>
> > It looks like the issue is fixed in later releases. And you’re running a
> > very old Kafka version TBF.
> >
> > Would an upgrade help ? If not, if you’ve got replication enabled (RF
> >=3)
> > you could try deleting broker files and recreating them by restarting the
> > affected broker.
> >
> > Thanks,
> >
> > Thanks,
> >
> > On Sun, 20 Oct 2019 at 13:30, Gur Aizenberg <gu...@gmail.com>
> wrote:
> >
> > > Hey guys,
> > >
> > > I am having a problem starting my Kafka Broker - I am using Kafka 0.11.
> > >
> > > When I try to start the broker I get the error:
> > > Fatal error during KafkaServer startup. Prepare to shutdown
> > > (kafka.server.KafkaServer)
> > > java.lang.IllegalArgumentException: inconsistent range
> > >
> > > I saw that there is a bug regarding this issue:
> > > https://issues.apache.org/jira/browse/KAFKA-7401
> > >
> > > Did anyone encounter this issue? Or knows how to fix this?
> > > Any help would be appreciated!
> > >
> > >
> > >
> > >
> > > Thank you,
> > > Gur
> > >
> >
>

Re: Kafka Broker not Starting

Posted by Gur Aizenberg <gu...@gmail.com>.
Hey,

Thank you for the reply.

Unfortunately an upgrade is not possible for us on this environment.

What would happen if I delete the broker files when RF < 3?
Data loss is something we can handle in order to bring this back up.

Currently we have a large number of under replicated partitions as well as
occurrences of broker failures.

Thank you for the help!

On Sun, Oct 20, 2019 at 5:20 PM M. Manna <ma...@gmail.com> wrote:

> It looks like the issue is fixed in later releases. And you’re running a
> very old Kafka version TBF.
>
> Would an upgrade help ? If not, if you’ve got replication enabled (RF >=3)
> you could try deleting broker files and recreating them by restarting the
> affected broker.
>
> Thanks,
>
> Thanks,
>
> On Sun, 20 Oct 2019 at 13:30, Gur Aizenberg <gu...@gmail.com> wrote:
>
> > Hey guys,
> >
> > I am having a problem starting my Kafka Broker - I am using Kafka 0.11.
> >
> > When I try to start the broker I get the error:
> > Fatal error during KafkaServer startup. Prepare to shutdown
> > (kafka.server.KafkaServer)
> > java.lang.IllegalArgumentException: inconsistent range
> >
> > I saw that there is a bug regarding this issue:
> > https://issues.apache.org/jira/browse/KAFKA-7401
> >
> > Did anyone encounter this issue? Or knows how to fix this?
> > Any help would be appreciated!
> >
> >
> >
> >
> > Thank you,
> > Gur
> >
>

Re: Kafka Broker not Starting

Posted by "M. Manna" <ma...@gmail.com>.
It looks like the issue is fixed in later releases. And you’re running a
very old Kafka version TBF.

Would an upgrade help ? If not, if you’ve got replication enabled (RF >=3)
you could try deleting broker files and recreating them by restarting the
affected broker.

Thanks,

Thanks,

On Sun, 20 Oct 2019 at 13:30, Gur Aizenberg <gu...@gmail.com> wrote:

> Hey guys,
>
> I am having a problem starting my Kafka Broker - I am using Kafka 0.11.
>
> When I try to start the broker I get the error:
> Fatal error during KafkaServer startup. Prepare to shutdown
> (kafka.server.KafkaServer)
> java.lang.IllegalArgumentException: inconsistent range
>
> I saw that there is a bug regarding this issue:
> https://issues.apache.org/jira/browse/KAFKA-7401
>
> Did anyone encounter this issue? Or knows how to fix this?
> Any help would be appreciated!
>
>
>
>
> Thank you,
> Gur
>