

The most important option to setup is the root of the paths to sync. The following gist shows the configuration of my master server: unison/default.prf and placed under the user’s home directory. Also, we can set those options using a configuration file. Unison provides an extensive set of CLI options that we can use to establish the sync configuration. Configuration must be set in the master, which is responsible for launching the sync process.


Unison must be installed on both master and slave. In this scenario, one of the servers acts as the master and the other as the slave. To keep things safe we will use SSH tunnels to transfer the data. Once installed we can sync two servers connected over the internet. We must use the -batch CLI option to launch the tool in batch mode to skip user intervention. Once installed, we can sync two directories running the following command: unison -batch dir1 dir2
#Unison filesync install#
In OSX, we must use homebrew to perform the installation: brew install unison In order to use the binary from a terminal, we must place it in a directory included in the system path.Īlternatively, in a debian-like distribution, we can install the tool using apt: sudo apt-get -y install unison
#Unison filesync download#
To install Unison we can download the precompiled binaries from here. Also, security is guaranteed because it can work over SSH tunnels. This tool works like rsync but it keeps stateful data supporting the bidirectional sync. It allows two replicas of a collection of files to be stored on different hosts (or different disks on the same host), modified separately, and then brought up to date by propagating the changes in each replica to the other. Unison is a file-sync tool for OSX, Unix, and Windows. There are several options to carry out this task, such as clustered file systems, but I have chosen a simple approach using Unison, a user-level tool that can be used to sync two replicas. This approach is simple and functional, but there is a problem: the sync must be bidirectional if we need to keep two identical replicas and avoid integrity issues. Until now, I was performing this task using the rsync tool and a cron task. Currently I am managing two little servers and I need to keep some data in sync. Here is a nice overview of the mentioned solutions along with some others that hopefully might be of help. Cloud storage can be very cheap or even free nowadays and having another copy somewhere else is a very good option because of multiple obvious reasons.
#Unison filesync software#
Another option that backup software can provide is a cloud tier. This way you can keep some versioning of files which might be extremely helpful. Unless you have a very special and specific case that requires such kind of approach I would rather stick to some sort of backup solution like RClone or Duplicati instead of regular file-based synchronization. Just run them at a regular manner and it will work. Rsync, Freefilesync, Unison - dozens of solutions will do the job. After this one is done you can use any Linux-based tool that can grab the files from your SMB share and put them into a folder on UnRAID. As already mentioned above, you need to expose your files over SMB for UnRAID to be able to access these files and copy them over.
