spam filtering software

 

MX records and load balancing

MX records provide a very simple means of load balancing. Especially where a gateway sitting in front of Exchange is filtering spam and virus, is concerned.

Gateways can easily become overloaded because spammers will send spam to anybody and anyone at mycompany.com. They run a dictionary of names against a domain, sending hundreds or thousands of spams per spree. 99% of which are addressed to mailboxes which do not exist, and will be rejected by Exchange if they do make it through the spam filtering.

Since gateways must accept all email for a hosted domain (See LDAP section or exceptions), they can quickly become overloaded trying to filter spam which ultimately would be rejected due to invalid recipient mailbox. Other than LDAP verification, there's little that can be done about this, except adding more bandwidth with additional gateways to handle the load.

By specifying the same priority level for two or more gateways, you can achieve a very simplistic level of load balancing between servers or gateways. For smaller organizations lacking more proprietary hardware and knowledge, this represents a perfectly reasonable method for alleviating an overloaded gateway or server.

Load balancing servers

In the case of a server, which is aware of mailboxes, one dedicated computer will be needed for mailboxes, message retrieval, and mailbox account information. It would be too unrooly to maintain the same mailbox account information on two or more servers, so a central account database will be needed. LDAP is an excellent choice for this, since it is widely supported, and designed to fit the bill quite well.

A centralized repository for recipients mailboxes will be necessary too, since the IMAP and POP3 protocols have no facility for collecting email from different mail stores. Indeed, this type of setup requires a separate POP3/IMAP server as a centralized mail store. And therefore verification and authentication should also be centralized.

POP3 and IMAP protocols present much less of a traffic load than seen on the SMTP side, and so depending on the size and complexity of an organization, it is reasonable to run two or more SMTP servers, load balanced using only MX records with equal priority, and a centralized POP3/IMAP server, also storing account mailbox information on OpenLDAP.

Obviously, your organizations situation will be different. You might already have an LDAP server or ActiveDirectory in your organization, from which your mail server can validate and your POP3/IMAP servers can authenticate. Or perhaps your mailbox account information is store in MySQL or Postgres. Either way, this discussions is less about clustering and more about the idea of using MX records to perform load balancing.