Rsync copies all files, not just changed files [Solved]

Khalid J Hosein kjh at
Fri Mar 5 11:54:10 MST 2010

On Mon, Mar 1, 2010 at 3:35 PM, Khalid J Hosein <kjh at pobox dot com>wrote:

> Hello all,
> I have a strange problem where rsync is copying over all files instead of
> just the ones that have changed.
> My setup:
> --------------
> Backup server runs a script that calls rsync in more or less this form:
>    "rsync --rsh=ssh user at /localbackup"
> Of course, I use a # of options, but the main ones are "-axS"
> Just in case, here are the other options I use: --delete --force --stats
> --cvs-exclude --bwlimit=100 --exclude-from=rsync-excludes.txt
> --delete-excluded
> Backing Up Other Machines
> ----------------------------------------
> I've tried and use this same script from the same backup machine against
> other servers (on different hosts) and found that the exact same set of
> options worked just fine.
> Other Tests
> -----------------
> I've scoured the lists and Web for solutions and tried things like
> --size-only, --ignore-times, --checksum and --whole-file. I've broken down
> my list of options to nothing and tried countless combinations (using dry
> runs), but haven't had any luck. I keep getting the notorious "Matched data:
> 0 bytes" in my stats.
> At this point, the only thing that I can think of is something to do with
> the target server (CentOS release 5.4,, i686), but I can't think of
> what exactly.
> Any help would be appreciated. TIA.
> _KJH

Well I think I've discovered the problem - the delete flags. I used:
"--delete --delete-excluded --force". Once I got rid of those, it started
behaving as expected, both from the script and directly from the command

I noticed that it seemed to be deleting every file in the destination before
sync'ing from the target. Even changing the --delete flag to --delete-after
didn't change this.

It's not ideal, but it's much better than re-sync'ing all of the data on
every backup. Thanks for the suggestions.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the rsync mailing list