After configuring a Courier mail server on a Debain squeeze server, I got this error on my mail client:

Filesystem notification initialization error — contact your mail administrator (check for configuration errors with the FAM/Gamin library)

The problem is related to libfam0. FAM is a service for system processes that need to watch file system alternations. Courier uses this library to update IMAP clients on folder status updates.

There are other solutions to provide file system modification alerting, including kernel specific systems like inotify or Kqueue, or portable libraries like FAM or Gamin.

Gamin is newer and an active project that provides the same API as FAM so is binary and source compatible with FAM with some differences.

Default Courier installation on squeeze uses libfam0, provided by the fam package. Since Gamin provides the same functionality Courier requires from libfam0, it is better to use Gamin instead of FAM. The Gamin package would remove fam package and install its own implementation of libfam0, fixing the error reported on the client side.

To install Gamin, open a terminal and enter:

sudo apt-get install gamin

This installation recommends removing fam and libfam0, accept the solution. Then restart courier-imap and courier-imap-ssl services:

sudo /etc/init.d/courier-imap restart
sudo /etc/init.d/courier-imap-ssl restart