0

I'm currently running Windows SMTP Server on a rented Windows 2003 Server VM. There are times when my hosting company network is down and my clients can't send their emails via the SMTP Server host I provide them with, e.g. smtp.mycompany.com.

I want to provide a failover solution so that if my primary Windows 2003 SMTP Server is down, all SMTP traffic will automatically be diverted to another VM hosted (smtp2.mycompany.com) located in another data center. Can this be done using Windows? I know there's HA proxy and Nginx but having to deal with Linux is beyond my capability - which is obvious otherwise I won't be asking such a novice question.:) However, I'm open to the possibility of renting a service that handles the failover. Thanks.

Joshua Lim
  • 251
  • 1
  • 3
  • 14

1 Answers1

2

You're over-thinking the problem. DNS already has a solution for you: multiple MX records. Add smtp2.mycompany.com as another MX record for your domain, but give it a higher preference value than your existing MX records. Senders will generally prefer the server with a lower preference.

I say generally because some broken MTA's just pick a random one, and some pick just the first one. A vast majority of those broken MTA's are spammers so there's no real loss there.

But if these are internal email servers for handling outgoing email, then MX records aren't going to help you. Possible options include:

  • load balancers (but you don't get data center survivability that way, only host survivability)
  • DNS based fail-over (you'd have to wait for DNS replication and client DNS cache timeouts to occur)
  • DNS load balancing (your client would have to be smart enough to repeat the DNS query for each SMTP retry)
longneck
  • 23,082
  • 4
  • 52
  • 86
  • thanks for replying. I have to set MX records when I setup my company domain for Google Apps Gmail. From my understanding, MX records are for the "receiving" SMTP Server. Does it also apply to "sending" SMTP Server. By sending SMTP server, I am referring to the Outgoing Mail Server client that is configured in Outlook mail client, for example, for Gmail, it is smtp.gmail.com, port 578. – Joshua Lim Jan 04 '13 at 17:22
  • Wait a second, what are you using these SMTP servers for? I assumed they were handling your inbound email. Are you just using them for sending mail? What can't you use Gmail's servers? – longneck Jan 04 '13 at 19:29
  • I'm filtering those outgoing emails, archiving, some more processing before sending out. – Joshua Lim Jan 05 '13 at 03:26
  • see my edits above – longneck Jan 07 '13 at 13:32
  • Thanks for the update. I'm also looking at a service based solution since I'd probably use a hosting company/cloud. Did some more research and discovered that Azure supports some sort of load balancing and failover. – Joshua Lim Jan 15 '13 at 23:58