GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing archive.kernel.org — Balance Filters - btrfs Wiki Balance FiltersFrom btrfs Wiki
Jump to: navigation, search
OBSOLETE CONTENTThis wiki has been archived and the content is no longer updated. Balancing to fix filesystem full errorsThis is explained in more details on Marc's Blog on Fixing Btrfs Filesystem Full Problems, but basically there are times when btrfs will need rebalancing to fix issues with chunks being misbalanced. Keys points:
btrfs balance start -v -dusage=0 /mnt/btrfs
btrfs balance start -dusage=55 /mnt/btrfs Other ExamplesConvert data to raid1 after mkfs with defaults You want to increase redundancy for data as well, with at least 2 devices you can do: $ mkfs.btrfs /dev/sda1 /dev/sdb1 $ mount /dev/sda1 /mnt [...] $ btrfs fi df /mnt output: Data, RAID0: total=409.50MB, used=0.00 Data: total=8.00MB, used=0.00 System, RAID1: total=8.00MB, used=4.00KB System: total=4.00MB, used=0.00 Metadata, RAID1: total=204.75MB, used=24.00KB Metadata: total=8.00MB, used=0.00 $ btrfs fi balance start -dconvert=raid1 /mnt $ btrfs fi df /mnt output: Data, RAID1: total=819.12MB, used=128.00KB System, RAID1: total=8.00MB, used=4.00KB System: total=4.00MB, used=0.00 Metadata, RAID1: total=460.75MB, used=24.00KB Metadata: total=8.00MB, used=0.00 Convert data and metadata to raid1 after mkfs with defaults The above example won't give you an actual RAID1 configuration if you haven't already mirrored your metadata, as it only mirrors data. You can see this if your output after running the above commands looks like the following: Data, RAID1: total=819.12MB, used=128.00KB System, DUP: total=8.00MB, used=4.00KB System: total=4.00MB, used=0.00 Metadata, DUP: total=460.75MB, used=24.00KB Metadata: total=8.00MB, used=0.00 You can also see it didn't work out the way you might have wanted to because $ btrfs fi show will report an unbalanced amount of space used on your devices. To actually get RAID1 where you are left with a working copy of the filesystem after you lose one of your devices, you must specify the following to rebalance to RAID1: $ btrfs balance start -dconvert=raid1 -mconvert=raid1 /mnt $ btrfs fi df /mnt
ViewsNavigationSearch |
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |