• This is a walkthrough for installing zfs from debian packages on a Raspberry Pi running Raspbian.
  • Get the OS onto a card with room to spare for zfs, or you can use/boot a USB drive with only /boot on the SD Card
  • uncomment deb-src line in sources.list and update packages
  • Remove unused kernel to make room on /boot and / (We will be very tight on space with a fresh, unexpanded install)
  • Install build tools and depends.
  • patch zfs_arc_max off by 1
  • Build it
  • disable swap (you can also rm the zfs and spl build directories to make more room)
  • Agree to the zfs license warning, then pick “No” to not abort building on a 32-bit kernel.
  • Check to see if zfs is loaded, if not load it.
  • Now create a pool, set the temp mount root to /mnt/rastank, and create a root dataset for easy snapshotting and rollbacks. It’s always a good idea to never put files in the pool without a dataset.
  • Now you can copy your system to the new ZFS partition. Use tar to preserve hard links and any special files. Install pv and di as helpful status utilities. If you don't want the progress to show, pipe the first tar command to the other.
  • make sure to edit the new fstab!!! remove the / entry
  • create initramfs with zfs support
  • verify zfs is in the initrd:
  • add this to config.txt: initramfs initrd.img-4.14.30-v7+ followkernel
  • you must update this when a new kernel is installed
  • example cmdline.txt to boot from zfs pool, limit zfs ARC to 64M:
  • Other things to do:
  • Problems:
  • ZFS files missing from initrd:
  • Tell dkms to build and install the missing zfs module:
  • ZFS cache file out of date or drive is missing: