Do different rsnapshot retains use the same hard links

backupincremental-backuprsnapshotrsync

Say I have a weekly and monthly backup configured in rsnapshot. Will the weekly backups create hard links to the same files created by a previous monthly backup (and vice versa)?

Best Answer

Yes.

On every rotation (hourly, daily, weekly, monthly), rsnapshot first does a cp -L ("copy" with hard links only), and then runs rsync, which deletes the links and replaces them with new/updated files.

If no files change during your whole rotation, you store only one copy of all files, and a bunch of links to the same data on disk.

If you enable debugging (verbose output), you can see the actual commands rsnapshot uses.

Related Topic