This documentation is for Dovecot v2.x, see wiki1 for v1.x documentation.

Quick Installation

If you just want to get Dovecot running with typical configuration in typical environment, here's what you'll have to do:

PAM

You'll probably be using PAM authentication. Make sure /etc/pam.d/dovecot exists. Here's a working example:

auth    required        pam_unix.so
account required        pam_unix.so

Mail Location

You can let Dovecot do its automatic mail location detection, but it that doesn't work, you set the location manually from default_mail_env setting.

Mbox

Make sure that all software accessing the mboxes are using same locking methods in same order. The order is important to prevent deadlocking. From Dovecot's side you can change these from mbox_read_locks and mbox_write_locks settings.

If you're using /var/mail/ directory for INBOXes, you may need to set mail_extra_groups = mail so Dovecot can create dotlocks there.

NFS

If you're using NFS or some other remote filesystem that's shared between multiple computers, you'll need to set mmap_disable = yes. You may also need to change lock_method setting. These settings are only used for handling index files.

Note that storing index files in NFS doesn't work perfectly yet, but as long as mailboxes don't get heavy concurrent accesses from multiple clients, it should work well enough. In any case you might want to store the index files in local disk instead. This is done by appending :INDEX=path to default_mail_env. For example:

default_mail_env = mbox:~/mail:INBOX=/var/mail/%u:INDEX=/var/indexes/%u

Remember that if you're storing indexes locally you can keep mmap_disable = no (which gives better performance).

Client Workarounds

Check imap_client_workarounds and pop3_client_workarounds and see if you want to enable more of them than the defaults.

POP3

If you're going to use POP3 server, you'll need to add pop3 to protocols line in configuration file.

You'll also have to set pop3_uidl_format setting. If you're migrating from another POP3 server, see [wiki:Migration migration page]. Otherwise set it to Dovecot's default:

pop3_uidl_format = %08Xu%08Xv