Backup with bash and rsync...
Posted
by
Roger
on Server Fault
See other posts from Server Fault
or by Roger
Published on 2011-07-01T15:08:31Z
Indexed on
2011/07/01
16:23 UTC
Read the original article
Hit count: 218
Is there a way to auto-rename an existing file on the receiver? For example: if filename
already exists, it auto-rename filename
to something like filename_001
, filename_002
and so on....
So far all I have is this:
$ rsync -rh --progress --stats --exclude '.thumb' \
--update --perms /origin /destination
By the way, I know rsync has --ignore-existing
to "skip updating files that exist on receiver", but I guess what I need would be something like --rename-existing
.
© Server Fault or respective owner