121
83
I have three computers at home, and would like to have the /home/
folder tree synchronized between the three.
Any files/folders (except those hidden) that are modified/added/removed in one of the three computers is updated in the other two.
Is rsync
enough to do this? and how?
5@Rabarberski many sync tools (including Unison or Syncthing) keep a database with references to the existing data (for this reason). It won't help you when syncing new folders for the first time, but they can very well delete files for you (automatically). The real problem with most sync tools is when files have been changed in two locations before the next sync occurs - in this conflict case you generally have to do a manual merge or maybe replace with the newest version. – Chris – 2015-08-03T09:06:46.713
2Syncing when the changes can't be instantaneously copied on the other machines is really tricky and I've never seen any program do it perfectly, so be prepared for a few bugs, conflicts, of reappearing files. I would recommend syncing only some specific folders that you know will be manageable by the syncing program. – Hey – 2017-06-01T10:56:50.660
10The problem with most 'syncing' tools, (including rsync if I recall correctly), is that they don't have a notion of user actions. So if you delete a file on computer X, the tool doesn't know whether (a) you actually deleted the file on computer X, or (b) that you added that file on computer Y. Most tools will assume (b), so upon syncing they will add the file again on computer X (instead of deleting it on computer Y). – Rabarberski – 2011-03-02T14:11:33.267