Cache store: SSD wear protection -- compaction policy, daily write cap, drive-type behaviour, write stats #709
Labels
No labels
amd
avatars
bug
builder
cannot-reproduce
crash
epic
feature
from-viewer
gl-removal
known-limitation
monitoring
parity
perf
platform
priority
critical
priority
high
priority
low
priority
medium
provenance
rendering
rt
status
in-progress
status
testing
status
up-next
triage
ui
upstream
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
sky_line/Slipstream#709
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Part of #715 (cache rewrite epic).
Compaction adds writes; keep SSD wear at or below today's file-per-item cache.
Scale: a heavy explorer might write ~12 GB/day of new cache data: ~0.7%/year of a 600 TBW 1 TB TLC drive, ~3%/year of a 150 TBW 500 GB QLC drive. Small, but bounded anyway:
/sys/block/*/queue/rotational, Windows storage seek-penalty query). SSD: minimal compaction only, no locality rewrites. HDD: locality rewrites allowed (see the HDD locality ticket).Large sequential appends and whole-segment deletes (one TRIM each) are also the SSD-friendliest write pattern, lowering the drive's own internal write amplification compared with small-file churn.
Interface audit (step 1 of #715): wear-relevant writes today and this ticket's slice of the store.
Writes today that the store removes or bounds
touchwriteUpdatedEntriesevery 300 s (:908)doWriteSlice of the interface
touch()never writes; access data rides the index snapshot (one sequential file).reuse_count> 0; everything else is evicted with the segment.Drop-in plan
Lands with the store core: in phase 1 only "no compaction while under budget" + whole-segment eviction + stats. Rescue, the daily cap and drive detection follow once eviction runs on real data. Stats show in the existing cache stats line and the log.
Fixed in 1.4.1 (
4c26bd0138). Reopen if you still see it.