jmcantrell / btrfs-snapshots

Manage timestamped collections of btrfs snapshots

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

btrfs-snapshots

Manage timestamped collections of btrfs snapshots.

This project is inspired by Snapper's timeline and cleanup algorithms, but with the aim of being a simpler implementation, focused solely on btrfs.

The goal is not to be a drop-in replacement, but an alternative for administrators that prefer a minimum of baked-in opinions.

Features

  • Retention policies based around recurring calendar events
  • Configurable snapshot locations for subvolumes
  • Minimal dependencies: bash and coreutils
  • Included systemd timers, but equally usable with cron
  • Included shell completion for bash and zsh

Installation

Repository

To install in the default location (/usr/local):

sudo ./scripts/install

To install in a different location:

PREFIX=/usr sudo ./scripts/install

Arch User Repository (AUR)

There are two packages available for Arch Linux, available via the AUR.

Stable, based on the latest tagged release: btrfs-snapshots

Unstable, based on the latest commit to the main branch: btrfs-snapshots-git

Help

Check out the man pages for detailed information about configuration and usage:

man 8 btrfs-snapshots
man 5 btrfs-snapshots

Testing

To run the included tests:

./scripts/test

To see the available options:

./scripts/test -h

About

Manage timestamped collections of btrfs snapshots

License:MIT License


Languages

Language:Shell 99.8%Language:Dockerfile 0.2%