rsync preserving symlinks on mirror

Keld Jørn Simonsen keld at dkuug.dk
Thu Jun 3 18:54:24 GMT 2004


On Thu, Jun 03, 2004 at 10:41:06AM -0700, Wayne Davison wrote:
> On Thu, Jun 03, 2004 at 07:23:33PM +0200, Keld J?rn Simonsen wrote:
> > I would like to be able to just do a
> > symlink from the original tree to the directory on the raid, 
> 
> Then you must either (1) tell rsync to expand all symlinks, (2) avoid
> having rsync copy the non-matching symlink, (3) duplicate the symlinked
> setup on the source so it matches the destination.
> 
> The first alternative is easy:  just use the -L option to rsync.  Note
> that EVERY symlink will be replaced by the file/dir it points to, so if
> you want to preserve symlinks, this option is not going to work.

Hmm, I want to keep the symlinks in the original tree. So I think there
is no way to have both: keeping the original symlinks and having my own
symlinks are mutually exclusive options. 

So I would need to go for your option 2...

I had hoped there was an option to do it, or I could have a new option
implemented, but I think that is not logically possible.

Best regards
keld


More information about the rsync mailing list