Bug 10024 - rsync cannot delete remote file, yet exit value is 0.
Summary: rsync cannot delete remote file, yet exit value is 0.
Alias: None
Product: rsync
Classification: Unclassified
Component: core (show other bugs)
Version: 3.1.0
Hardware: All All
: P5 normal (vote)
Target Milestone: ---
Assignee: Wayne Davison
QA Contact: Rsync QA Contact
Depends on:
Reported: 2013-07-16 12:51 UTC by Andreas Krüger
Modified: 2014-05-15 14:16 UTC (History)
1 user (show)

See Also:

Shell script that shows the problem. (1.15 KB, application/octet-stream)
2013-07-16 12:51 UTC, Andreas Krüger
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Andreas Krüger 2013-07-16 12:51:17 UTC
Created attachment 9052 [details]
Shell script that shows the problem.


Some recursive rsync that should have deleted a remote subdirectory with some files in it. It cannot do that, as the permissions on the remote machine don't allow deletion.


rsync should give a useful error message and terminate with an exit value that is not 0.


While rsync does give a useful error message, it terminates with exit value 0.

I enclose a script that demonstrates the problem, with rsync version 3.0.9 on both ends.
Comment 1 Wayne Davison 2013-07-19 16:00:05 UTC
Please test 3.1.0dev instead.
Comment 2 Andreas Krüger 2013-07-19 21:01:15 UTC
I grabbed the git sources as of 2013-07-13 and buildm62327b1281be9151423048235573e0ca208fc095 on my machine. Used that compile results on both ends, by using localhost and adding --rsync-path in my script as provided.

The bug reproduces with that version.
Comment 3 Wayne Davison 2013-12-23 18:33:14 UTC
I checked in a fix for this the other day.  Thanks for the report!
Comment 4 Peter 2014-05-15 14:16:50 UTC
The same problem persists for flags --remove-source-files, no error value is returned when remote files could not be deleted, eg. due to no write permissions. Tested on 3.1.1pre version.