Do you need to build Btrfs in Raspberry Pi?

Do you need to build Btrfs in Raspberry Pi?

BTRFS is HUGE compared to most other filesystems. I’d expect building it in to increase the kernel memory footprint by 100kB+. Raspbian uses (and requires) an initrd, because of this, BTRFS does not need to be built-in to be used as a root filesystem. BTRFS development is moving fast.

What kind of RAID data does Btrfs support?

Btrfs also supports RAID5 and RAID6, which use parity data to increase data robustness, reliability and recoverability. I have chosen not to include those levels in this brief overview, because they are much less commonly used in desktop systems and by casual users.

Do you need initrd to use Raspberry Pi?

Raspbian uses (and requires) an initrd, because of this, BTRFS does not need to be built-in to be used as a root filesystem. BTRFS development is moving fast. Far faster than the Raspberry Pi kernel (4.9 just got released upstream, and Raspbian, NOOBS, and most other things are still shipping 4.4).

Do you need initrd to use Btrfs?

Raspbian uses (and requires) an initrd, because of this, BTRFS does not need to be built-in to be used as a root filesystem. Raspbian neither uses nor requires an initrd. You can configure the kernel to use one, but it isn’t a tested configuration.

How to convert Raspbian root to Btrfs root?

$ fsck.ext4 /dev/mmcblk0p2 # Optional but I recommend it $ btrfs-convert /dev/mmcblk0p2 # Convert ext4 root to btrfs $ mkdir /mnt/sdcard # Here we will mount the rootfs $ mount -t btrfs /dev/mmcblk0p2 /mnt/sdcard # Mount newly created rootfs Now we edit /etc/fstab and change ext4 to btrfs.

Can you use Raspbian Buster with Btrfs?

Until openSUSE Leap will be available, I’m using Raspbian Buster which comes by default with ext4. Since I want to have snapshots, the first thing I want to do is to convert the existing root partition into btrfs. So let’s do this. 0. Get Raspbian First, flash Raspbian to a SD card and boot it.