Btrfs is a copy-on-write Linux file system with snapshots, checksums, subvolumes and built-in multi-device support. It is the default on openSUSE and Fedora Workstation, and on Synology NAS units and some other appliances. It is actively developed in the kernel.
Overview
Btrfs stores everything in copy-on-write B-trees keyed by (objectid, type, offset): the root tree, the chunk tree, the extent tree, file system trees and others. Space is allocated in chunks mapped from logical to physical addresses, which allows multiple devices and RAID profiles. The superblock at 64 KiB has two backup copies. Data and metadata are checksummed (CRC-32C by default) and may be compressed (zlib, LZO, zstd).
History
Started by Chris Mason at Oracle in 2007.
Merged into Linux 2.6.29 (2009).
Became the default on Fedora Workstation 33 (2020).
Structures
Offsets are in bytes from the start of the structure named in each heading. Field names are descriptive and are not an official specification. Fixed-width integers are shown as u/i (unsigned/signed) followed by bit width and byte order.
Structures and constants were extracted from the implementation. Prose sections are a summary from public sources; verify details before relying on them.