Bugzilla – Bug 1219930
btrfs-balance kernel 6.7 metadata over-allocation
Last modified: 2024-04-08 20:22:51 UTC
Upstream report: https://lore.kernel.org/linux-btrfs/CAL3q7H5UaYcAYHijBO+QTnnpruVQXvdirg05_X94KRKrKnXDZw@mail.gmail.com/T/ Patches have been submitted for 6.8-rc5: https://lore.kernel.org/linux-btrfs/cover.1707900530.git.dsterba@suse.com/T/#u The patches aren't in the stable tree yet, and there are no backports in the openSUSE stable branch as of now, afaict. The default setting for scheduled btrfs balance in the btrfsmaintenance package is "weekly", and 6.7 is in TW since beginning of February, so people will be hurt by this issue now.
Assiging to Filipe, as he's been working on the issue upstream.
The In the meantime, the wasted metadata space can be reclaimed with: sudo btrfs balance start -musage=1 / if this command results in 'No space left on device' like it did on my system (despite 'estimated free space' being multiple GBs), try first with -musage=30 then again with -musage=1
Could you push those to the stable branch, please?
I am not sure which of Filipe's patches are required for fixing this issue. I'd be really grateful if Filipe could have a look himself.
In the meantime, I took David's: https://lore.kernel.org/all/20240215133633.25420-1-dsterba@suse.com/
(In reply to Jiri Slaby from comment #5) > In the meantime, I took David's: > https://lore.kernel.org/all/20240215133633.25420-1-dsterba@suse.com/ 1693d5442c45 btrfs: add and use helper to check if block group is used f4a9f219411f btrfs: do not delete unused block group if it may be used soon 12c5128f101b btrfs: add new unused block groups to the list of unused block groups 2f6397e448e6 btrfs: don't refill whole delayed refs block reserve when starting transaction