MaxBlockDuration is 31 days when only using size based retention configuration
Author: richardwilkoCreated Feb 21, 2020Updated Sep 26, 2026
Labelshelp wantedkind/enhancementpriority/P3component/tsdb
cfg.tsdb.MaxBlockDuration defaults to 31 days, not 10% of 31 days when only using size based retention.
Bug is in on line 313 of prometheus\cmd\prometheus\main.go, the 10% scaling only applied when the retention duration is non-zero, but retention duration is zero when setting only storage.tsdb.retention.size
Currently an issue on master
Source: prometheus/prometheus