Does --archive include an --update behaviour?
Stefan Nowak
p.org at gmx.at
Fri Nov 27 21:30:23 MST 2009
Manpage of rsync 3.0.6 about option --update: [...] This forces rsync
to skip any files which exist on the destination and have a modified
time that is newer than the source file. [...]
Here the manpage is very clear to me!
But if I don't use that option: Would rsync overwrite newer files at
the destination with older files from the source?
The --archive manpage section says nothing about this issue... So I am
getting insecure.
How does --archive behave when a newer file is at the destination?
I am thinking about this, because I am thinking about the restore
process. If I keep a certain filtered subset of my original as a
backup, and then my original partially brakes (example: incidental
file deletion) I would use:
rsync -au backup/ original/
In order to put everything back, except where content at the original
is newer, or identical (=did not get missing through the incidental
file deletion in our example). What I want to avoid is that a newer
file is at the destination, and nevertheless it gets replaced by the
old version from the backup!!! What of course cannot be avoided,
because rsync can simply not know it, is that intentionally deleted
files since the last backup at the destinations get restored from the
backup. But with this I could live, and just do a manual "disk spring
cleaning".
Thanks for clarification help in advance!
Regards, Stefan Nowak
More information about the rsync
mailing list