btrfs: add sysfs switch to get/set metadata size
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest3 patches 10 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/3 | btrfs: store chunk size in space-info struct.fs/ fs/ fs/ | +53 | 2 replies | |
| 2/3 | btrfs: expose chunk size in sysfs.fs/ | +94 | 2 replies | |
| 3/3 | btrfs: add force_chunk_alloc sysfs entry to force allocationfs/ | +58 | 3 replies |
Reviews trailers per patch
None of the 3 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.
| Patch | Josef Bacik |
|---|---|
| Series | R-b |
| 1/3 | |
| 2/3 | |
| 3/3 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH v1 0/3] btrfs: add sysfs switch to get/set metadata size
The btrfs allocator is currently not ideal for all workloads. It tends to suffer from overallocating data block groups and underallocating metadata block groups. This results in filesystems becoming read-only even though there is plenty of "free" space.
This patch adds the ability to query and set the metadata allocation size.
Patch 1: btrfs: store chunk size in space-info struct.
Store the stripe and chunk size in the btrfs_space_info structure to be able to expose and set the metadata allocation size.
Patch 2: btrfs: expose chunk size in sysfs.
Add a sysfs entry to read and write the above information.
btrfs: add force_chunk_alloc sysfs entry to force allocation
For testing purposes and under a debug flag add a sysfs entry to force a space allocation.
Stefan Roesch (3):
btrfs: store chunk size in space-info struct.
btrfs: expose chunk size in sysfs.
btrfs: add force_chunk_alloc sysfs entry to force allocation
fs/btrfs/space-info.c | 41 ++++++++++++ fs/btrfs/space-info.h | 3 + fs/btrfs/sysfs.c | 152 ++++++++++++++++++++++++++++++++++++++++++ fs/btrfs/volumes.c | 28 +++----- 4 files changed, 205 insertions(+), 19 deletions(-)
base-commit: dfd42facf1e4ada021b939b4e19c935dcdd55566
Signature · 1 line
2.30.2