General objective: Student will be able to build a reliable and scalable mailserver cluster capable of serving 100K+ ISP users Session 1: Overview (Introduction: intention is to give a cookbook of working examples to build your own large mail cluster. Get some idea of services they would like) Objectives: student will be able to - give basic structure of an E-mail message - define and distinguish MUA and MTA - describe how DNS is used in mail delivery - use telnet to port 25 and port 110 to manually send and retrieve E-mail - explain purpose of envelope and distinguish from RFC822 headers - list key approaches to improve scalability (separate smtp and pop3 servers; Maildir vs mbox; no linear password files; replicate front-ends and storage back-ends; eliminate points of failure) - list other desirable features of a mail server (IMAP; webmail; SMTP delivery to client; per-user quotas; no Unix accounts per user; individual accounts and whole domains per mailbox; open standards and interchangeable parts) - explain why we are using exim rather than sendmail - describe the basic exim mail processing mechanism (local_domains; routers/directors; spool) - find their way around exim documentation Session 2: Exim configuration Objectives: student will be able to: - install exim - configure exim as a basic outgoing SMTP relay - replace sendmail using /etc/mail/mailer.conf - restrict relaying to local addresses only, explain why this is important, test policy using exim -bh - read and interpret mailq and exim log files inc. paniclog/frozen messages - perform queue runs on individual messages and the whole queue - use exim -C and -bt to try out a configuration file and debug delivery problems (modify configuration file for Maildir delivery) - use configuration file for a good performance SMTP smarthost (non-root, tweaked for large-scale installation) - configure relaying, outbound and backup MX Session 3: Mailserver performance tuning and monitoring - Install qmail-pop3d and test it (Unix accounts) - FreeBSD: configure maxusers 512, softupdates, ccd striping - run exim as non-root - install postal and use it to generate bulk SMTP deliveries - test pop3 performance using rabid - use existats, exicyclog and eximon (and df, uptime, ...) Session 4: Database driven operation; virtual domains - explain what is meant by 'virtual domains' - explain why it is desirable not to have accounts in /etc/passwd - assign hashed directories, create dbm files for domains and mailboxes, and configure exim to use them - create a 'whole domain' mailbox and a single-user mailbox Session 5: POP3 and IMAP configuration - create a userdb for courier http://courier.sourceforge.net/userdb.html - install courier-imap (with 'deliverquota') - start pop3 and imap daemons, deliver and retrieve mail [as time allows: sqwebmail] Session 6: Clustering technologies - describe scaling using round-robin DNS/multiple MX records and layer 4 switching - mount NFS backend(s), configure mail to be distributed across multiple backends - configure exim as a database-driven SMTP frontend - install and use a database-driven POP3 proxy http://perdition.sourceforge.net/ and/or http://www.i2pi.com/smunge/ - be able to distribute database using rsync, demonstrate awareness of LDAP and SQL (practical exercise will end up with the whole class as a huge mailserver cluster :-) Other topics which might be discussed ------------------------------------- SMTP end-user delivery, ETRN SMTP authentication RBL policy controls