Ubuntu Linux: Syncing Documents between Different Computers Using NFS and Unison

The other day I successfully made a full transition from my laptop to my desktop as my primary development environment. The biggest hurdle before completing this transition was transferring and syncing documents between my two laptop and desktop. For quick file transfers, I created a network file share, or NFS, on my desktop, while mounting the drive on my laptop. For a quick overview on how to setup and mount NFS, consult this thread on Ubuntu forums.

I also wanted to sync and compare documents from a centralized server and have the ability to compare differences between a client and a centralized ‘master’ copy. (think Subversion – but without all the permissions and change logging) After a quick Google search, I found a wonderful program called ‘Unison’. This program will allow a user to define a master directory on a server and slave directory on a client. Master being the label for the directory where all clients compare their files and slave as clients that send new files or receive files copied from other clients to the master directory. For directions on installing unison, consult this article on howtoforge.com.

Leave a Reply