I'm trying to determine if rsync can possibly corrupt source data during a copy.

I understand that the if the source file is being modified, deleted, renamed, etc, rsync may produce a corrupted destination file.

Is it possible that if the source file is being modified by another process (text file to which data is being added, for example). Is it possible rsync could change and/or corrupt the source file?

I looked at this answer on stack but it mainly talks about the possibly of destination corruption.

  • I know that's not what you are asking, but did you consider using a code management solution that is designed for this purpose (and offers many other benefits) instead of caring how to make another tool safe for this purpose?
    – Philippos
    Jul 4, 2017 at 14:11

1 Answer 1


rsync NEVER writes to, or modifies, the source file in any way.

  • It will delete the source file after a successful and verified copy if you specify the --remove-source-files flag. (Specifically, this will fail safely and not delete the source file if it is modified during the copy.)
  • The filesystem may update the last access timestamp on the source file if it is configured to do so

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.