24

In the source directory I have some symbolic links. These links point to some paths and data is present in those paths also; but using rsync it is copying only the link files, not the data that is present in the path.

lrwxrwxrwx 1 lafter lafter   58 Sep 26 16:57 8770 -> ../../../../.sites_repository/brest/8770/3.2.08.05.b-b0001
lrwxrwxrwx 1 lafter lafter   59 Sep 26 16:57 bootdvd -> ../../../../.sites_repository/colombes/bootdvd/12.1.013.000

Any solutions?

2
  • Try it with the explicit paths rather than the dotted back path or whatever and see what result you get for a simple test. – Drink More Pimp Juice IT Oct 15 '17 at 23:09
  • 5
    Does this answer your question? rsync and symbolic links – Ryan Dec 21 '19 at 19:58
30

man rsync says:

-L, --copy-links    transform symlink into referent file/dir
1
  • 2
    Thanks. This copied the symbolic links target's content. – Rakesh Gupta May 1 '19 at 2:57

Not the answer you're looking for? Browse other questions tagged or ask your own question.