Plain round-robin load balancing breaks IMAP. Two backends serving the same user produce conflicting indexes, missing messages, and UIDVALIDITY mismatches that re-download whole mailboxes.
Director's job: map each user to exactly one backend at a time, with sticky failover.
[ Client ] → [ Director cluster ] → consistent-hashes user → [ Backend N ]
Two deployment shapes:
- Director-only proxy: Director runs on dedicated hosts, proxies IMAP/POP3 to backends.
- Director-on-backend: Each backend runs director. Simpler, fewer moving parts.
Most production setups choose #2.
Required pieces:
- All backends share the same auth (passdb returns the same userdb).
- All backends mount the same mail storage (NFS, GlusterFS, Ceph, or replication).
- Directors cluster among themselves via
director_servers.
Sign in to keep track of what you have read.