Re: Is it safe to delete old log segments manually?

2021-03-25 Thread Peter Bukowinski
In this case, yes, for any given topic-partition on the broker, you should be able to delete the oldest log segment, its associated index and timeindex files, and the snapshot file (which will be recreated on startup) in order to gain some free space. — Peter Bukowinski > On Mar 25, 2021, at 1

Re: Is it safe to delete old log segments manually?

2021-03-25 Thread Sankalp Bhatia
Thank you for the response Peter. However, for us all the brokers are currently offline. So if I delete the entire topic-partition directory in one of the brokers, the first broker would start with no means to replicate the data which we just deleted. What are your thoughts on this? Do you think th

Re: Is it safe to delete old log segments manually?

2021-03-25 Thread Peter Bukowinski
Hi Sankalp, As long as you have replication, I’ve found it is safest to delete entire topic-partition directories than it is to delete individual log segments from them. For one, you get back more space. Second, you don’t have to worry about metadata corruption. When I’ve run out of disk space

Is it safe to delete old log segments manually?

2021-03-25 Thread Sankalp Bhatia
Hi All, Brokers in one of our Apache Kafka clusters are continuously crashing as they have run out of disk space. As per my understanding, reducing the value of retention.ms and retention.bytes properties will not work because the broker is crashing before the log-retention thread can be scheduled