A common misconception is that outbound email can be load-balanced for Exchange simply by provisioning two equal cost Send Connectors, either using DNS to route directly or routing via a smart host for each Send Connector.
When the cost of the Send Connectors and the proximity to their source servers are the same, Exchange will simply choose the one with the alphanumerically lower connector name, and will not load balance the outgoing email across both connections.
The correct solution is to deploy a single Send Connector with multiple smart hosts.
Note: this blog post written by me originally appeared on All Spammed Up, which is no longer an active website. The article has been retrieved from the internet archive, thanks to Tostka in the comments below.
Some organizations wish to deploy complete end to end redundancy for their Exchange environment, including the outgoing routes to the internet.
To achieve this most organizations will simply provision a backup internet connection for their network. This connection can either be activated during an outage of their primary link, or be configured as a secondary route that will be automatically used if the primary route is down.
Although this seems like a simple win it can cause problems with email delivery because of IP reputation issues.
You need to be sending email fairly consistently from an IP address in order to maintain a decent reputation for that mail source. If you treat a second location as a cold standby, only used when your main ISP breaks, expect to see serious delivery problems as you migrate across to it.
In other words unless you are continually sending email out both of your email routes you might create new problems for yourself when you start using the backup connection. So what is the solution?
Better to spread load across both locations, to keep both sets of addresses “warm”
Load Balancing Outgoing Email with Exchange Server
A common misconception is that outbound email can be load-balanced for Exchange simply by provisioning two equal cost Send Connectors, either using DNS to route directly or routing via a smart host for each Send Connector.
However this is not true.
If multiple equal cost connectors are available to route email, E2007 Routing picks one of the connectors deterministically… Mail will not be load balanced among multiple equal cost connectors.
When the cost of the Send Connectors and the proximity to their source servers are the same, Exchange will simply choose the one with the alphanumerically lower connector name, and will not load balance the outgoing email across both connections.
The correct solution is to deploy a single Send Connector with multiple smart hosts.
If the smart hosts are on your own network then they are configured to route to the internet via their respective ISP connection.
Or if the smart hosts are actually hosted by the ISP then the Send Connector simply specifies the IP addresses or DNS names of the smart hosts, and the Exchange source servers would need static routes configured to be able to reach each smart host over the correct ISP connection.
When multiple smart hosts are configured on a single Send Connector the outgoing email will be correctly load balanced.
If a smart hosted SMTP Send Connector has multiple smart hosts defined, load balancing and fault tolerance are accomplished using these smart hosts.
In summary, to achieve outgoing email load balancing with Exchange Server 2007 and 2010 without creating delivery problems due to IP reputation:
- Do not configure multiple equal cost Send Connectors
- Do configure a single Send Connector with multiple smart hosts
Good evening Paul, I always follow your good advice, I have this question, in the case of an exchange configured to use 2 accepted domains, for example, abc.com and xyz.com, I created two users named peter and joseph in the active directory , and I assigned its corresponding email address, and it works by receiving the emails in the corresponding mailbox from an external email, but how do I make each mailbox send emails out, using its own sending connector, configured with its corresponding domain, no I get it to work, the mailbox chooses the connector with the highest priority, then only the mail goes out from the mailbox whose send connector is configured with his domain, which I still have to complete, I don’t know if I explained myself clearly, in advance, thanks
Love the Internet. 8yrs later and this article was a life saver!
Hi Paul,
This is very nice article. I have two smart hosts and accoriding to your instructions have configured the two smart hosts in one send connector.
My question is what mechanism or technique Exchange used to load balance the smtp/email trafic to smart hosts?
Moreover, if one smart host goes down then Exchange will be able to detect failure automatically and will start sending emails only to smart host 2?
Once first smart host online again then Exchane will detect it and then start load balancing the stmp trafic again?
I think all those questions are actually answered in the article and in other comments that people have already posted.
I thing none off those questions are answered. I’m also curious how Exchange will work if one of smart host goes down. Someone told me that Exchange uses round-robin if more than one smart host is configured in send connector. As I know round-robind don’t have any detection mechanizm so Exchange wouldn’t now that one off smart hosts is down.
Can you confirm that Exchange don’t use round-robin in this situation and it can detect failure of one smart host?
Ok, so this actually didn’t work for us. We could NOT get it to fail back to the second smart host. Mail would just sit in the queue for the first connector. Subsequent mail would drop in there too even after mail failed to be sent. The only way we could get it to failover was to disable the first connector and restart the transport service. At that point, mail would be put into the 2nd connector and go out. Worked but not automatically.
We did find a solution though. It was this:
http://c7solutions.com/2012/05/highly-available-geo-redundancy-with-html
Basically, you create a “dummy” zone in AD DNS, then create “A” records to your two smart hosts. Then create two MX records that each point to the two smart hosts at different sites and make local one a higher priority than the 2nd remote smart host.
It is the best solution without any extra cost.
If you have a loadbalancer, you may configure the 3 IPs in one pool and assign the remote site IP as a failover.
So let’s say I WANT to only use one smart host at a time, but I want to have a 2nd one in case the first one has an issue. Could I create 2 send connectors each with different smart host IPs, and give my backup a higher cost? So if the first one becomes unavailable, it will send out the higher cost connector?
Yes.
Hi Paul,
using 2 exchange 2013 not in a DAG. Created 2 send connector and added only one of each servers in source server. In short, sendconnector 1 has server1 added and sendconnector2 has server2 added.
When users in server 1 send out email, every second mail are sent using sendconnector1.
Means mail 1 sent through sendconnector1 and mail 2 going through sendconnector2.
Is this by design? Is it possible at all to only allow one server using one send connector only?
Thanks and keep up the good work!
Why do you have two send connectors?
No, this is not true. This doesn’t work.
Just a heads up, GFI ‘bitbucketed’ the original All Spammed Up post (now redirs to their homepage). I dug up a copy it at the Internet Archive:
https://wayback.archive.org/web/20140411014315/https://www.allspammedup.com/2010/06/avoiding-ip-reputation-problems-with-redundant-mail-paths/
Thanks for noticing that.
Realy nice tip!!! But I need something a bit different:
my exchange 2010 manages 7 domains, I need 3 of them to be routed throug a smart host , the remaining 4 domains have to be routed directly by DNS resolution.
I don’t know how and if it is possible.
Any help will be appreciate.
Thank you in advantage.
Francesco.
To my knowledge Exchange doesn’t natively support conditional routing of outbound mail based on sender domain.
Hi Paul,
Thanks for your infomation for Outbound Email, but How is about the Inbound direction.
What i mean here is the Smart Host Configuration of the Default Internal Send Connector of Edge Subscription process: EdgeSync – Inbound to .
The — placeholder in the list of smart hosts represents all the Hub Transport servers that are located in the subscribed Active Directory site and is the literal character displayed
(http://technet.microsoft.com/en-us/library/aa997438(v=exchg.141).aspx)
But when i want this connector to load balance accross exactly 02 HUB TRANSPORT, can i remove the “–” place holder and add 2 specific IP’s address of the 02 HUB TRANSPORT SERVER ?? Does it will load balance accross these two HUB TRANSPORT smart host ?
Thanks Paul very much !
Hello,
BUT, how is it handled when i add two sendconnectors with different smtp-servers and same ( or maybe different ) cost.
Are the mails sent via the second send-connector if the first is unreachable?
thank you
marko
Can you explain how does Exchange 2010 detect a fault with a SmartHost? Like does it do ping or anything similar?
I’ve never really looked into it. I doubt it relies on ping since its possible that pings are being blocked while SMTP is allowed.
My assumption is that the server tries to connect on TCP 25 (SMTP) and if it can’t then it considers the host to be unreachable.
Nice tip! i was looking for this answer!