--delete causes rsync failure

Kaleb Pederson kaleb.pederson at gmail.com
Tue Nov 13 07:46:06 GMT 2007


Hello,

I just narrowed down an rsync command that keeps failing to the --delete flag:

rsync -vv --delete --backup-dir=backup_target --archive /etc myuser at localhost:

It gives the following output:

...
backup_dir is --delete/
building file list ...
done
Invalid file index: 1868985864 (count=0) [receiver]
delta-transmission enabled
rsync error: protocol incompatibility (code 2) at sender.c(189) 
[receiver=2.6.9]
rsync: connection unexpectedly closed (144421 bytes received so far) 
[generator]
rsync error: error in rsync protocol data stream (code 12) at io.c(458) 
[generator=2.6.9]
rsync: connection unexpectedly closed (12 bytes received so far) [sender]
rsync error: error in rsync protocol data stream (code 12) at io.c(458) 
[sender=2.6.9]

I have confirmed that the above rsync command causes the following to be 
excecuted on the server side:

rsync --server -vvlogDtpr --backup-dir backup_target --delete .

backup_target exists within the myuser account and has correct permissions.

I find it odd that it says "backup_dir is --delete/" when it isn't.  I looked 
at the docs and they indicated that backup_dir is generally used 
with --backup (-b), but adding that doesn't help.

The exact same command, without the --delete works correctly.  And, if I 
switch --delete to --delete-after, everything works correctly.  Ignoring the 
errors doesn't help either.

Any ideas? Am I missing something in the docs?  Is this a bug?

Thanks for the help.

--Kaleb


More information about the rsync mailing list