0

I am using rsync to backup my server to an offsite server. Due to diskspace on my backup server, I have created a couple of symlinks to put some of the data on a different drive. However, instead of copying through to that symlink location, rsync is deleting the symlink and replacing it with a real directory.

How can I get rysnc to copy through the symlink on the destination?

David
  • 829
  • 3
  • 13
  • 30

2 Answers2

1

I think you need to use the option --no-implied-dirs.

For more info, see man rsync.

Look at the paragraph that explains the usage of this option.

Khaled
  • 35,688
  • 8
  • 69
  • 98
0

According to the manpage, the -l flag to rsync:

-l, --links                 copy symlinks as symlinks

should do what you want.

MadHatter
  • 78,442
  • 20
  • 178
  • 229