Machine readable log and directory layout metadata

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Machine readable log and directory layout metadata

Samba - rsync mailing list

do you know a way/tool to save the directory layout that was synchronized to a file?

So you later know there was a file "foobar" that was copied from the source to dest, and another file foobarcommon that existed in both. And know the size/mtime/hash of both.

There is the log-file option, but it does not seem to be machine readable. Especially files that have line breaks in their name completely mess up the log.

And the log-file uses MD5, which is outdated nowadays. Something like SHA-2 or newer would be more appropriate.

And I would like to know the entire directory layout, not just the changes in the log. So when you delete a file, it can check, the file was there during the previous synchronization, but now it is gone, so delete that file in the destination. This is different to a non-existing file, a file that does not exist now and did not exist previously, would not need to be deleted.

Or when there a file X with a hash was deleted, but there is a new file Y in the source and a file X in the destination that all have the same hash, it is likely that we do not need to copy Y, and can just rename X in the destination directory. At least with a strong hash like SHA-2

Since rsync knows which files are in a directory when it is syncing it, it has all the necessary information, so how can they be accessed and remembered?

I know about unison, but it solves a different problem, since it ties a source-destination together, rather than storing changes in one directory.


Please use reply-all for most replies to avoid omitting the mailing list.
To unsubscribe or change options:
Before posting, read: