I set up a shell script to synchronize two directories, this is the code:

rsync -rptDH /source /destination

Source is a local directory and destination is a smb mounted NAS drive.

I added the -H option because I am very interested in keeping the hard links existing in the source.

When the script is executed I get the following message:

kernel[0]: smbfs_vnop_link: warning: pid 774(rsync) hardlink(filename)

I suspect there is a problem in keeping hard links in the destination disk. Is there a way to solve this?

  • Does SMB/Samba even support hard links? Does it work if source and destination are both on a HFS formatted drive? – nohillside Oct 4 '16 at 17:22
  • @patrix: thanks for asking that question, I've made some research and found the second answer in this page: stackoverflow.com/questions/1348269/nfs-hard-links is totally right is totally right, hard links make no sense when you are copying files from one filesystem to another. – naio Oct 5 '16 at 10:11
  • If the destination system supports hard links, AND the actual file is one of the files to be copied, then it makes plenty of sense. – WGroleau Dec 6 '16 at 0:19

You must log in to answer this question.

Browse other questions tagged .