I'm rsync'ing a bunch of files between a Windows and a Linux system. Since not all Windows care about case, some of the files on the Windows system no longer have the same casing as they had on the Linux system. But rsync now treats these files as different and uploads a new copy.

Is it possible to have rsync ignore the case?

link|improve this question
feedback

3 Answers

You could try using rsync's fuzzy matching system:

-y, --fuzzy

This option tells rsync that it should look for a basis file for any destination file that is missing. The current algorithm looks in the same directory as the destination file for either a file that has an identical size and modified-time, or a similarly-named file. If found, rsync uses the fuzzy basis file to try to speed up the transfer.

Note that the use of the --delete option might get rid of any potential fuzzy-match files, so either use --delete-after or specify some filename exclusions if you need to prevent this.

link|improve this answer
feedback

There is no specific option to make rsync case-insensitive. Although, NTFS preserves case so you shouldn't have much problem with it. On the other hand, FAT filesystems have more issues with rsync and such a combination should be avoided.

link|improve this answer
feedback
up vote 1 down vote accepted

Rsync has what they call a "maintained patch" that adds an --ignore-case switch. You need to compile rsync from source for this, and apply ignore-case.patch. You need the patched rsync version on both the local as the remote side.

link|improve this answer
Why is this not in the main code? Why leave a patch unapplied? GNU tar has --ignore-case, and can easily switch between case-sensitive exclude files and case-ignored exclude files on the same command line. – Brendan Byrd Apr 28 at 16:06
feedback

Your Answer

 
or
required, but never shown

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