Collection of scripts used for data backup and snapshots, i.e. for btrfs and lizardfs.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

29 lines
902 B

7 years ago
Use BTRFS Snapshots For Backups
===============================
7 years ago
7 years ago
btrfs-snapshots.sh
------------------
7 years ago
7 years ago
Creates a snapshot for all btrfs volumes specified. Snapshot is named
from the subvol name or if there is no subvol, from the path by
appending `-snapshot-YYYY-MM-DD-HH-mm`.
To create regular snapshots on a daily base, just run:
7 years ago
sudo cp btrfs-snapshots.sh /etc/cron.daily/btrfs-snapshots
7 years ago
If `btrfs-snapshots` is run from a `cron.daily`, `cron.hourly`,
`cron. monthly` or `cron.weekly` directory, the periodity is
automatically appended to the snapshot name, and the expiry is set
meaningfull.
Try: `btrfs-snapshots.sh --help`
Installation
------------
7 years ago
7 years ago
Just call `./install.sh` to install all cron jobs. Then there will
always be the last 24 hourly backups, the last 7 daily backups, tha
last 4 weekly backups and all monthly backups of all your btrfs
filesystems mounted in `/etc/fstab`.