Document Archive: btrbk-0.13

NAME

btrbk.conf − btrbk configuration file

SYNOPSIS

/etc/btrbk.conf
/etc/btrbk/btrbk.conf

DESCRIPTION

The btrbk configuration file specifies which btrfs subvolumes on the filesystem are to be processed, what target subvolumes should be used to create the backups, and where the snapshots should be generated. The retention policy as well as other options can be defined for each backup.

The options specified always apply to the last section encountered, overriding the same option of the next higher section. This means that global options must be set before any sections are defined.

The sections are:
volume
<volume-directory>|<url>

Directory of a btrfs volume (or subvolume) containing the source subvolume(s) to be backuped (usually the mount-point of a btrfs filesystem mounted with the subvolid=0 option).

subvolume <subvolume-name>

Subvolume to be backuped, relative to the <volume-directory> specified in the volume section.

target <type> <volume-directory>|<url>

Target type and directory where the backup subvolumes are to be created. In the current version of btrbk, the only valid <type> is “send−receive”.

For the volume and target sections, you can also specify a ssh-url instead of a local directory. The syntax for <url> is:

ssh://host.xz/path/to/volume

The configuration options are:
snapshot_dir
<directory>

Directory in which the btrfs snapshots are created. Relative to <volume-directory> of the volume section. Note that btrbk does not autmatically create this directory, and the snapshot creation will fail if it is not present.

snapshot_create_always yes|no

If set, the snapshots are always created, even if the backup subvolume cannot be created (e.g. if the target subvolume cannot be reached). Defaults to “no”. Useful for subvolumes on laptops to make sure the snapshots are created even if you are on the road.

incremental yes|no|strict

Perform incremental backups. Defaults to “yes”. If set to “strict”, non-incremental (initial) backups are never created.

target_preserve_daily all|<number>

How many days of backups should be preserved. Defaults to “all”.

target_preserve_weekly all|<number>

Defines for how many weeks back weekly backups should be preserved. Every backup created at preserve_day_of_week (or the next backup in this week if none was made on the exact day) is considered as a weekly backup. Defaults to “0”.

target_preserve_monthly all|<number>

Defines for how many months back monthly backups should be preserved. Every last weekly backup in a month is considered a monthly backup. Defaults to “all”.

snapshot_preserve_daily
snapshot_preserve_weekly
snapshot_preserve_monthly

Define retention policy for the snapshots, with same semantics as the target_preserve_* options.

preserve_day_of_week monday|tuesday|...|sunday

Defines on what day a backup/snapshot is considered as a weekly backup. Defaults to “sunday”.

ssh_identity <file>

Absolute path to a ssh identity file (private key). Note that if the private key is password protected, btrbk will prompt for user input, which is usually not desired.

ssh_user <username>

Remote username for ssh. Defaults to “root”. Note that you will have to make sure that the remote user is able to run /sbin/btrfs (which needs root privileges).

btrfs_commit_delete after|each|no

If set, make sure the deletion of snapshot and backup subvolumes are committed to disk when btrbk terminates. Defaults to “no”.

receive_log <file>|sidecar|no

Dump verbose output of btrfs receive to a specified file. If set to “sidecar”, the file will be created in the backup directory, named <backup_subvolume>.btrbk.log. Note that this log file can become very big, as every change of every file is being logged. Consider this as a debugging feature. Defaults to “no”.

Lines that contain a hash character (#) in the first column are treated as comments.

AVAILABILITY

Please refer to the btrbk project page http://www.digint.ch/btrbk/ for further details.

SEE ALSO

btrbk(1)

AUTHOR

Axel Burri <axel@tty0.ch>

« prev | next »