log.local.retention.bytes — Kafka Broker Configuration
The maximum size of local log segments that can grow for a partition before it gets eligible for deletion. Default value is -2, it represents `log.
Description
The maximum size of local log segments that can grow for a partition before it gets eligible for deletion. Default value is -2, it represents `log.retention.bytes` value to be used. The effective value should always be less than or equal to `log.retention.bytes` value.
Default Values by Kafka Version
| Kafka Version | Default Value |
|---|---|
| 3.6 | -2 |
| 3.7 | -2 |
| 3.8 | -2 |
| 3.9 | -2 |
| 4.0 | -2 |
| 4.1 | -2 |
| 4.2 | -2 |
Tuning Recommendation
| Profile | Recommended | Why |
|---|---|---|
| broker / cost | 1073741824 | Caps local disk usage to 1GB per partition when tiered storage is enabled, complementing time-based local retention for predictable disk capacity planning. |
Related Configs
remote.log.storage.system.enable · log.local.retention.ms
Manage Kafka configs across all your clusters with Conduktor Console — view, compare, and update configurations in one place.