I encountered a weird file corruption problem with rsync.
I have a perl script that generates and writes a data file to disk, then
rsyncs the file to a remote machine. A perl script running on the remote
machine periodically reads in the data file.

However, occasionally the remote script will barf while processing the
data file, and I tracked down the problem to file corruption.

I suspected rsync was the problem, so I changed the generation script to
rsync to a different file name, then remotely rename/ overwrite the file
with the new data file (using mv over ssh). And the file corruption
problem is gone.

Now from what I understand, rsync supposedly do the same thing: rsyncs
to a temporary file, then renames it. So what went wrong?

To unsubscribe or change options: https://lists.samba.org/mailman/listinfo/rsync
Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html