Switch smarthosts in Exchange when using dual WAN

exchangesmarthostsmtpwide-area-network

I'd like to know if it's possible to setup Exchange 2003/2007 to switch between smarthosts, based on the WAN connection currently in use.

Example scenario: I have two WAN connections with different ISP's. Exchange is running behind a dual WAN router. The router is setup to fall back to secondary WAN when primary WAN fails. The smarthost set in Exchange is the SMTP server of the primary ISP. Because the smarthost set in Exchange only allows relaying from IP's of the primary WAN sending mail won't work when the router falls back to the secondary WAN.

Sending mail directly through DNS MX lookup is an option but the ISP's have dynamic IP's that get blacklisted a lot.

Thanks in advance!

Best Answer

There's nothing built in to Exchange 2003 or 2007 to do this for you. Exchange 2007 can be managed via Powershell, however, and the component that controls your smarthost is a Send Connector in Exchange 2007 and you could write a Powershell script that changes that attribute without too much effort. Whether or not you would want this to somehow run automatically or not would determine how complex this would need to be.