How to sync an exact list of files, Including deletes!?

Matt McCutchen matt at
Tue Nov 23 16:29:45 MST 2010

On Tue, 2010-11-23 at 23:35 +0100, Axel Kittenberger wrote:
> > You want the --delete-missing-args option of the current development
> > rsync.
> Yes, I suppose I want that! :-) I hope this works with --force as well
> if there is a dir in --files-from?


> I got another question tough running extensive tests, the daemon
> happens to do this once in a while if creates/deletes/moves piling up
> faster than inotify tracks, it calls rsync for a source->destination
> pair, where the source dir no longer exists, normally would be no
> problem:
> $ /usr/bin/rsync -vP  -d /tmp/ltest.WQS/src//n/c/d/ /tmp/ltest.WQS/trg//n/c/d/
> building file list ...
> rsync: change_dir "/tmp/ltest.WQS/src//n/c/d" failed: No such file or
> directory (2)
> 0 files to consider
> created directory /tmp/ltest.WQS/trg//n/c/d
> I expect rsync to just fail in that case, but it creates the target
> directory nevertheless :-( Is there some parameter I can add to rsync
> so it wont create directories on the target, if there isnt a source
> directory for it?

Rsync always creates the destination directory; there is no way to stop
that.  I would suggest using /tmp/ltest.WOS/trg/ as the destination
directory in combination with --relative.


More information about the rsync mailing list