How to remove files at source present on destination without transferring them

Wayne Davison wayned at samba.org
Tue Aug 21 11:11:45 MDT 2012


On Sat, Aug 18, 2012 at 2:47 AM, David Liontooth <lionteeth at cogweb.net>wrote:

> Does rsync provide a way to remove files at the source that are present on
> the destination, without first transferring the files?
>

If the file that is already on the destination is identical to the one on
the other server's source (including modified-time), then a normal copy
(w/--remove-source-files) will notice they are identical and just remove
the source file.  If the times differ, you can use --checksum and it will
just tweak the time instead of doing an all-matching-data transfer.  If you
want to avoid the checksum time, you could consider using --size-only, but
only if you are sure that identically-named files of the same size are
always the same.

..wayne..
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.samba.org/pipermail/rsync/attachments/20120821/6667f68e/attachment.html>


More information about the rsync mailing list