User:Hfern/Drafts/btrbk

Btrbk is a backup tool for btrfs subvolumes, taking advantage of btrfs specific capabilities to create atomic snapshots and transfer them incrementally to your backup locations. Having btrfs partitions is therefore a prerequisite to using using btrbk.

Installation
Btrbk is in portage.

Additional software
When btrbk is used to transfer backups to a central backup server some additional software may be required:
 * ssh is used to transfer backups to a remote server. Package is a dependency
 * mbuffer can be used to speedup the communications. It would need to be installed on the backup server. It's package is not a dependency, see also.

Terminology
Throughout this article certain btrfs and btrbk terms and concepts are used and it's best to define them first:
 * : a btrfs root subvolume, with subvolid=5
 * : a read/write btrfs subvolume under a volume
 * : a readonly btrfs subvolume with a parent-uuid
 * : a btrbk read-only subvolume created with send/receive, with a received-uuid.

Configuration
Btrbk installs a well documented sample configuration file at. Copy it to, and adapt it to your requirements. The configuration file has some general settings, and settings per volume that needs to be backed up.

global settings
These settings can be defined on a global level, but can be overriden per volume.
 * transaction_log: location of the log
 * stream_buffer: the size of the in memory buffer used by mbuffer, if a remote backup server is used
 * snapshot_dir: relative to the volume. Note that btrbk does not create this directory.