Is there any way to restore/create hardlinks lost in incremental backups?

Dan Stromberg drsalists at gmail.com
Mon Dec 14 00:54:27 UTC 2020


On Sun, Dec 13, 2020 at 11:59 AM Wayne Davison via rsync <
rsync at lists.samba.org> wrote:

> I should also mention that there are totally valid reasons why the dir
> might be huge on day4. For instance, if someone changed the mode on the
> files from 664 to 644 then the files cannot be hard-linked together even if
> the file's data is unchanged. The same goes for differences in preserved
> xattrs, acls, and ownership.  In such a case you could decide that you
> don't care about the change in meta info and tweak it on the earlier files
> to match day4's files and then the suggested re-link command would decide
> it could join them together.  You'd probably then need to keep going and
> re-link day5's pictures (since it was probably linking to the old day4's
> pictures).
>
> ..wayne..
>

I totally get why some folks would prefer to use rsync --link-dest for
backups: It's very fast, and the backup itself is usable as a replacement
filesystem.

If you are open to trying something else though, there are probably several
tools at
https://stromberg.dnsalias.org/~strombrg/backshift/documentation/comparison/index.html
that can backup permissions changes without needing to create a copy of the
file data.  Sadly, I don't know about most of the tools there, but I know
that backshift wouldn't.  Backshift is much slower than rsync, but also
takes up quite a bit less storage space, even if you mv a large hierarchy
or change all the file permissions in a hierarchy.

HTH
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.samba.org/pipermail/rsync/attachments/20201213/2e199e0a/attachment.htm>


More information about the rsync mailing list