<div dir="ltr"><div dir="ltr"><div><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature">On Sun, Nov 28, 2021 at 12:53 PM Cristian via rsync <<a href="mailto:rsync@lists.samba.org">rsync@lists.samba.org</a>> wrote:<br></div></div></div><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><font face="monospace">$ rsync --copy-unsafe-links -avz --delete tree XXX</font><br></blockquote><div><br></div><div>In this case, the "tree" directory is a part of the transfer inside the top-of-transfer dir (the current directory). Thus any symlinks that don't try to escape the current directory are considered to be OK.  You should instead suffix "tree" with a slash and add "tree" to your destination path:</div><div><br></div><div><font face="monospace">$ rsync --copy-unsafe-links -aivz --delete tree/ host:/old/path/tree/</font></div><div><font face="monospace"><br></font></div><div><font face="monospace">This is discussed in the <a href="https://download.samba.org/pub/rsync/rsync.1">man page</a> (search for "unsafe").</font></div><div><font face="monospace"><br></font></div><div><font face="monospace">..wayne..</font></div></div></div>