public inbox for linux-btrfs@vger.kernel.org
 help / color / mirror / Atom feed
* Converting from single to raid0 creates a ton of unused data chunks
@ 2022-09-17 16:00 Roman Mamedov
  0 siblings, 0 replies; only message in thread
From: Roman Mamedov @ 2022-09-17 16:00 UTC (permalink / raw)
  To: linux-btrfs

Hello,

Just finished converting the remaining "single" data chunks on my FS to
"raid0", with btrfs-progs v5.10.1, kernel 5.10.140.

Before:

  Data, RAID0: total=200.00GiB, used=193.06GiB
  Data, single: total=107.00GiB, used=105.12GiB
  System, RAID1: total=32.00MiB, used=48.00KiB
  Metadata, RAID1: total=2.00GiB, used=488.64MiB
  GlobalReserve, single: total=353.98MiB, used=0.00B
  WARNING: Multiple block group profiles detected, see 'man btrfs(5)'.
  WARNING:   Data: single, raid0

Converting:

  # btrfs fi balance start -dprofiles=single -dconvert=raid0,soft /mnt/ssdm/
  Done, had to relocate 110 out of 209 chunks

After:

  Data, RAID0: total=412.00GiB, used=297.21GiB
  System, RAID1: total=32.00MiB, used=48.00KiB
  Metadata, RAID1: total=2.00GiB, used=466.83MiB
  GlobalReserve, single: total=332.31MiB, used=0.00B

As you can see it created a ton of "slack" in the RAID0 Data allocation.

Sure, I can collapse it down with:

  # btrfs fi balance start -dusage=50 /mnt/ssdm/
  Done, had to relocate 56 out of 209 chunks

And the result will be:

  Data, RAID0: total=302.00GiB, used=297.21GiB
  System, RAID1: total=32.00MiB, used=48.00KiB
  Metadata, RAID1: total=2.00GiB, used=466.83MiB
  GlobalReserve, single: total=332.19MiB, used=0.00B

But is this expected? I wonder what if this somewhat runaway chunk creation
would face no more free space to allocate for these, would the balance fail
with ENOSPC then?

-- 
With respect,
Roman

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-09-17 16:00 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-09-17 16:00 Converting from single to raid0 creates a ton of unused data chunks Roman Mamedov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox