cockroachdb / cockroachdb/cockroach

storage: tune reserved space based on filesystem type

オープン
#93,178 コメント 2 件 リアクション 0 件 担当者 0 名 GitHub で見る
A-storage C-enhancement T-storage
主要言語
Go
スター
32.5k
フォーク
4.1k
PR マージ指標
PR 指標を取得中

説明

Different filesystems should have different reserved capacity. Modern versions of ext[2-4][1]reserve 5% of blocks as the high watermark for available disk space (see `-m`). ZFS should use ~82% (value from personal experience, mostly due to the correlation between zpool utilization, disk fragmentation, and work required to find a free block to perform a write).

> looking at a roachtest out-of-disk failure, we noticed that the node crashed with `ENOSPC` at 95%. This is because ext4 reserves 5% space for the root user by default. However, this interacts poorly with some of our heuristics that try to halt writes at 95% to prevent running out of disk (e.g. AddSSTable ingestion and rebalancing), because at 95% we're already out of disk. This reserved space also serves a similar purpose to our ballast files, in that the root user can reallocate it to CockroachDB in an emergency.

[1] [mkfs.ext4](https://linux.die.net/man/8/mkfs.ext4)

Jira issue: CRDB-22206

コントリビューションガイド

コントリビューションガイドを開く

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。