-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Thu, Feb 16, 2017 at 11:44:32AM +0100, Francesco Porro wrote:
> 
> 
> On 16/02/2017 09:15, to...@tuxteam.de wrote:
> > rsync.
> >
> > To a LUKS-encrypted USB drive (my laptop's drive is LUKS, so it seemed
> > to be a majot weak point to have all on an unencrpted thumb I could lose
> > anytime ;-)
> > [cut]
> 
> that's very similar to my current backup-style, I use rsync with a lot
> of options as for eg "--exclude-from=exclude.txt --> this file contains
> all the folder I do not want to copy to the destination dir.
> 
> the drawback of all this is the lack of a snapshot/multi-level backup, a
> feature that would be very useful to me.

That depends on what you mean by "snapshot" and "multi-level". If what you
want is full backups without repeating all the stuff, check out the
- --compare-dest and --link-dest options With this, you can make a backup
and the files which didn't change are just hard linked to their old version.

Since it's all hard links, you can "garbage collect" by just rm-ing old
stuff.

I had such a contraption running at a customer's (many moons ago) which made
hourly backups and kept two week's worth of backups: just at top level there
was a directory structure indexed by date/time and below a whole tree of
their data. I exported it (read only!) via Samba, and from there on, they
"Just Knew" what they had to do when they inadvertently busted That Important
File.

Now if you are talking about "Real Snapshots" (i.e. files don't change
during backup and stuff), then you've got to look into either LVM
(they say performance isn't the best) or into special file systems
(btrfs, zfs) which are really magic in this respect.

With rsync you'll always have some skew (i.e. the world is changing
while the backup is running). Don't back up a database's binary image:
always back up its dumps, or better: use the database facilities
for that.

> Anyway, I didn't know the .backup-filter stuff and it seems a very smart
> and simple tool. Thank you Tomás for sharing the whole procedure!

Yeah: the hardest (but most beautiful) part about rsync is reading its
man page. I still discover things, after years of use.

regards
- -- tomás
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iEYEARECAAYFAlilh1sACgkQBcgs9XrR2kaPIACcC1/n49YZFsYIeQWyk4YtNpS3
RNgAn107ILUEZZ5n1ML2gdgitHI11rFd
=zGSr
-----END PGP SIGNATURE-----

Reply via email to