Using Unison on Specific Operating Systems
Generic Unix Questions
Is it OK to mount my remote filesystem using NFS and run unison locally, or should I run a remote server process?
NFS-mounting the replicas is fine, as long as the local network is fast enough. Unison needs to read a lot of files (in particular, it needs to check the last-modified time of every file in the repository every time it runs), so if the link bandwidth is low then running a remote server is much better.
I've heard that the Unix file locking mechanism doesn't work very well under NFS. Is this a problem for Unison?
No.
What will happen if I try to synchronize a special file (e.g., something in /dev, /proc, etc.)?
Unison will refuse to synchronize such files. It only understands ordinary files, directories, and symlinks.
Is it possible to run Unison from inetd (the Unix internet services daemon)?
Toby Johnson has contributed a detailed chroot min-HOWTO describing how to do this. (Yan Seiner wrote an earlier howto, on which Toby's is based.)
OS X
Does Unison work on Mac OSX?
Quite well! Download it (both GUI and text, and Universal-binaries) from http://alan.petitepomme.net/projets/unison/
Recent versions of Unison work well on OS X, including support for synchronizing files with resource forks, handling of creator strings, etc. Both the text-mode interface and a native OSX graphical user interface are available. (Thanks in particular to Ben Willmore for huge improvements to the latter!)
A couple of caveats:
Trying to sync resource forks is probably not worth the time and trouble for most users, so to tell unison to ignore resource forks, include this line in the profile:
- rsrc = false
- Unison will be confused by some files that are frequently updated by OSX, and will report lots of errors of the form "XXX has been modified during synchronization." These files --- in particular, files with names like .FBCLockFolder and .FBCIndex --- should be ignored by adding these lines to your profile:
ignore = Name .FBCIndexignore = Name .FBCLockFolder
The wiki may wrap big lines below, so unwrap so everything after "ignore = " is on just one line.
- ignore = Name {Cache*,.Trash*,.VolumeIcon.icns,.HSicon,Temporary*,.Temporary*,TheFindByContentFolder}ignore = Name {TheVolumeSettingsFolder,.Metadata,.filler.idsff,.Spotlight,.DS_Store,.CFUserTextEncoding}
Spotlight (10.4+) and TimeMachine (10.5+) running in background can slow down your mac, and you may want to temporarily disable them during a big sync. Also, it may be possible to tell spotlight never to index a folder by making the name end in ".noindex" For example, you could create in /Users/Shared/ a folder named Downloads.noindex and tell Firefox to store downloads there.
- Unison does not run on Mac OS 9 or earlier.
Can Unison synchronize an OS X machine with a Unix machine?
Yes, but new OS X users may be confused by restrictions on file names: although OS X respects case in file names, two files whose names differ only in case may not coexist on the same file system. If such files exist on the Unix side, Unison will report the error but not identify the offending files. Unix users can identify such files with the aid of a script like this:
Installing Unison from Fink (on OS X) does not work.
We've had reports that fink installation only works when the unstable packages are selected. See for more information.
How do I install a Terminal only Unison using Darwinports?
Mac Geekery has a short tutorial describing how to do it.
How do I pass environment variables to the Aqua version of Unison?
Create a file .MacOSX/environment.plist in your home directory containing:
For more information about this file, see ??? .
Windows
Try these few steps to install unison-gui on windows.
- Install pidgin http://www.pidgin.im/download/windows/ (this will install the gtk pre-requisite)
- Download unison zip files from http://alan.petitepomme.net/projets/unison
- Extract/copy the unison*.exe files from the zip file to c:\program files\common files\GTK\2.0\bin
- Right-click on the unison*gtk.exe (in above "bin" folder) and send to desktop (to create a shortcut).
