From bcb1a947562e4d3b86145ebd75b69b48c89af68b Mon Sep 17 00:00:00 2001 From: Bernie Innocenti Date: Tue, 10 Aug 2021 01:27:57 +0200 Subject: [PATCH] Improve docs. --- README.md | 40 +++++++++++++++++++++++++++++++++------- 1 file changed, 33 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 33e031f..1f0dda4 100644 --- a/README.md +++ b/README.md @@ -1,14 +1,31 @@ -== List the machines to backup == +Wizbackup is a minimalistic backup system based on rsync and hardlinked +snapshots. +Its main feature is that each backup snapshot is a plain filesystem tree, identical to the +original. Theere's no need for a tool to restore and manage backups. + +There are a few downsides to this simple structure: + - Backups are uncompressed (unless the underlying filesystem supports transparent complression) + - Large files which change every day, such as logs and databases, are duplicated in each snapshot, + wasting space. Reflinks (aka COW-links) would solve this. + + +Setup +===== + +List the hosts to be backed up: + +``` mkdir -p /backup/HOSTS cat >/backup/HOSTS/example <<__EOF__ host1.example.com host2.example.com __EOF__ +``` +Optionally, specify paths to be excluded from backups: -== Optionally, exclude files from backups == - +``` mkdir -p /backup/EXCLUDE cat >/backup/EXCLUDE/ALWAYS <<__EOF__ /dev/ @@ -17,23 +34,32 @@ cat >/backup/EXCLUDE/ALWAYS <<__EOF__ /sys/ /selinux/ __EOF__ +``` + +You can also specify host-specific excludes: +``` cat >/backup/EXCLUDE/host1.example.com <<__EOF__ /var/cache __EOF__ +``` +Install the wizbackup cronjob: -== Install wizbackup cronjob == - +``` cat >/etc/cron.daily/wizbackup <<__EOF__ #!/bin/bash wizbackup-driver /backup/HOSTS/example /backup __EOF__ +``` +Create an ssh keypair for each host: -== Create an ssh keypair for the hosts == - +``` mkdir -p /etc/wizbackup ssh-keygen -N '' -c "wizbackup@example.com" -f /etc/wizbackup/ssh_id ssh-copy-id -f /etc/wizbackup/ssh_id.pub root@host1.example.com ssh-copy-id -f /etc/wizbackup/ssh_id.pub root@host2.example.com +``` + +That's it! -- 2.25.1