Rsync --Copy-links problem

Wayne Davison wayned at samba.org
Thu Apr 12 15:09:56 GMT 2007


On Wed, Apr 11, 2007 at 10:30:41AM +0530, Namitha Rao wrote:
> I went through rsync tutorial and found --copy-links options to do my
> job i.e, to transform symlink into referent file/dir

Yes, --copy-links works fine, as long as rsync can actually get to the
referent file.  Since you're accessing an rsync daemon, I'd imagine that
you have "use chroot" enabled (since that's the default) and that the
links point outside the chroot area (which is not accessible, by
definition).  So, you'll either need to turn off chroot, or you'll need
to transform the symlinks in the daemon area into files (which you could
do by using a find command and copying the real files over the links, OR
by changing the copy you used to populate that area to use rsync with
the --copy-links option).

Keep in mind that turning off chroot means that you won't be able to
copy those out-of-chroot symlinks into the module using an rsync daemon
(since they are considered to be unsafe).  You'd need to either use a
chroot rsync module for the inward copy and a non-chroot module for the
outward copy, or use --copy-links for the inward copy.

..wayne..


More information about the rsync mailing list