conduktor.io ↗

log.segment.bytes — Kafka Broker Configuration

The maximum size of a single log file.

Description

The maximum size of a single log file

Default Values by Kafka Version

Kafka VersionDefault Value
0.8.01024 * 1024 * 1024
0.8.11024 * 1024 * 1024
0.8.21024 * 1024 * 1024
0.9.01073741824
0.10.01073741824
0.10.11073741824
0.10.21073741824
0.11.01073741824
1.01073741824
1.11073741824
2.01073741824
2.11073741824
2.21073741824
2.31073741824
2.41073741824
2.51073741824
2.61073741824 (1 gibibyte)
2.71073741824 (1 gibibyte)
2.81073741824 (1 gibibyte)
3.01073741824 (1 gibibyte)
3.11073741824 (1 gibibyte)
3.21073741824 (1 gibibyte)
3.31073741824 (1 gibibyte)
3.41073741824 (1 gibibyte)
3.51073741824 (1 gibibyte)
3.61073741824 (1 gibibyte)
3.71073741824 (1 gibibyte)
3.81073741824 (1 gibibyte)
3.91073741824 (1 gibibyte)
4.01073741824 (1 gibibyte)
4.11073741824 (1 gibibyte)
4.21073741824 (1 gibibyte)

Tuning Recommendation

ProfileRecommendedWhy
broker / throughput536870912Reducing segments to 512MB means segments roll more frequently, enabling faster log compaction and retention enforcement without accumulating 1GB of data per partition before any cleanup can happen. At very high write rates, smaller segments reduce the window of data at risk if a single segment is corrupt.
broker / cost268435456Smaller segments (256MB) allow the retention enforcement loop to reclaim disk more granularly. With 1GB segments, a topic that hits its retention byte limit must wait for a full 1GB segment to be eligible for deletion; with 256MB segments, cleanup is 4x more precise.

Related Configs

log.retention.bytes · log.retention.hours · log.index.size.max.bytes · background.threads · log.retention.check.interval.ms · log.segment.delete.delay.ms · num.partitions

Manage Kafka configs across all your clusters with Conduktor Console — view, compare, and update configurations in one place.