0

I have two shared hosting servers and I need to sync a directory with subfiles/directories using rsync via SSH automatically.

Mean: If server1 had changed server2 updates the changes. If server2 had changed server1 updates the changes.

I can use cron but I don't know the best way to do that.

  • 1
    You're describing shared fs, for instance NFS. You cannot achieve that with rsync since rsync uses the changes vector, *source -> destination*, and in your case there's no constant direction. Bet that question will be voted down and closed. – drookie Feb 10 '22 at 04:29
  • @drookie As I understood from you, with `rsync` there is only `Master` -> `Slave`, I cant use `Master`<->`Master` right? If your answer is yes, Can you tell me the ways to do it? – Mohamed Gamal Eldin Feb 10 '22 at 14:24
  • `unison` allows to do `Master <-> Master` synchronization. – Patrick Mevzek Feb 19 '22 at 18:04

0 Answers0