Re: btrfs based backup?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2019-11-12 1:34 p.m., Ulli Horlacher wrote:

> Set up a backup server with btrfs storage (with compress mount option),
> the clients do their backup with rsync over nfs.
> 
> For versioning I make btrfs snapshots.
> 

My KISS script to do exactly this looks like so:
(Permissions on the backup are handled by default ACL's on the receiving
end.)

/usr/bin/rsync \
	-a --no-o --no-g --no-p --chmod=ugo=rwX --info=STATS \
	--inplace --exclude='.snapshots' --delete \
	/nas/  \
	backup.server:/backups/server/nas/ \
    || exit 1

/usr/bin/ssh backup.server \
  "/bin/btrfs file defrag -r -t 32M /backups/server"


/usr/bin/ssh backup.server \
  "snapper -c server create -c number" \
  || exit 1

Attachment: signature.asc
Description: OpenPGP digital signature


[Index of Archives]     [Linux Filesystem Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux