change of behaviour on rsync -R and top level symlinks?
wayned at samba.org
Fri Jun 18 23:44:45 MDT 2010
On Wed, Jun 16, 2010 at 1:37 PM, Marc MERLIN <marc at merlins.org> wrote:
> I should keep my /a -> /c symlink on the destination without
> --no-implied-dirs since I have /a -> /c on the source too, and this is what
> rsync 2 did.
See the --relative option in the man page:
Beginning with rsync 3.0.0, rsync always sends these implied directories as
real directories in the file list, even if a path element is really a
symlink on the sending side. This prevents some really unexpected behaviors
when copying the full path of a file that you didn’t realize had a symlink
in its path. If you want to duplicate a server-side symlink, include both
the symlink via its path, and referent directory via its real path. If
you’re dealing with an older rsync on the sending side, you may need to use
the --no-implied-dirs option.
So, in your case, you're wanting to both duplicate the /a symlink, and
something down in the /c heirarchy, so you could copy both /a (the symlink)
and /c/b (the real hierarchy) in the same transfer. Or just use --no-i-d,
as you discovered.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the rsync