Back to Engineering Blog
Incident Review 6 min read

When the Database Filled the Disk: An Incident Write-Up

A time-series database exhausted its disk and went down. What we did, what we deleted, why it was safe, and what we changed.

Jason NevillBy , Houston, TX
#Incident#TimescaleDB#Retention#Postmortem

Key Architectural Takeaways

  • Root cause: raw data compresses poorly, so the retention window could never fit the disk.
  • Recovery freed space by dropping one derived, rebuildable data chunk, with the raw source intact.
  • Smaller chunks, faster compression and shorter raw retention now keep the footprint bounded.

What happened

The disk on the data host reached 100% and the database was killed, pausing collection for about half an hour.

Cause

  • Raw order-book data compresses poorly, so a long retention window could never fit the disk.
  • One derived table only compressed after a day-long chunk had closed, so a single chunk grew very large.
  • One table had no retention at all.

Recovery

  1. Reclaimed small amounts of space and restarted the database.
  2. Dropped a single derived chunk that could be rebuilt from raw data still on disk, then compressed the others.
  3. Cancelled a compression job whose temporary files were about to refill the disk, and paused it until it was safe.

Changes

Smaller time chunks, compression within hours instead of a day, shorter raw retention (a regular sync keeps the permanent copy elsewhere), and a retention policy for the table that lacked one. We recorded every deletion and the reason in the incident log.

Follow the build on LinkedIn or by RSS.

All Articles

Follow the build

Questions about the build, or spotted something we got wrong? Find us on LinkedIn and GitHub.