Home / Companies / ClickHouse / Blog / Post Details
Content Deep Dive

What is direct I/O, and why does ClickHouse Managed Postgres use it for backups?

Blog post from ClickHouse

Post Details
Company
Date Published
Author
-
Word Count
3,527
Company Posts That Month
22
Language
English
Hacker News Points
-
Post removed?
No
Summary

Direct I/O allows backup software to bypass Linux’s page cache, preventing large live PostgreSQL backups from evicting database data that queries may soon need and avoiding an additional kernel memory copy. ClickHouse Managed Postgres found that while buffered backup reads displaced warm but temporarily idle pages and increased query latency, Direct I/O preserved cached data, reduced latency impact and CPU use, but also disabled kernel readahead, which can reduce throughput on RAID0 NVMe arrays when reads are too small. To address this, its configuration sizes direct reads according to the number of drives so each request spans the stripe and adjusts parallel reader counts for hardware such as dense NVMe instances. Tests on a 467 GB database backed by four NVMe drives showed that tuned Direct I/O maintained warm cache contents, kept query p99 latency near baseline, and completed in roughly the same time as buffered backups, whereas default small Direct I/O reads were slower. The approach is generated per server, includes rollback flags for compatibility issues, and is intended to support future incremental backups that reduce the amount of data uploaded while retaining the same local I/O protections.

Trends Found in this Post
Trend Post Mentions Total Month Mentions Posts Companies MoM
Real-time 1 2,637 756 207 -45%
Use This Data

Use this post, company, and trend context to find content marketing opportunities, perform competitive analysis, or address product feature gaps via the Plushcap MCP server or the Plushcap API.