My ASP.NET application running in IIS7 on Windows Server 2008 needs to send email. I added the SMTP feature to Windows Server 2008. The problem is that my server has multiple IP addresses and I don't seem to have any control over what IP is used for the outgoing email. Email is sent correctly, but the "Fully Qualified Domain Name" I'm using to send mail may not match the IP the server uses:
http://forums.iis.net/t/1158540.aspx
Any ideas on how I can fix this? Please keep in mind I'm mainly a programmer and only a part time sys admin.
ADDITIONAL QUESTION: What do people think about just using external SMTP servers like Google Apps SMTP servers? Are they reliable enough?
I recommend using HMailServer instead as it is free and much better (finer SMTP controls, better logging/troubleshooting tools). You can disable the POP and IMAP functionality easily.
Anyway, you should be able to change the IIS SMTP binding per below. It looks like it is for inbound, but it may also work for outbound. If not, I think it might bind to the first IP address in Windows, so you can make the IP you want to be the outbound the primary IP on your system. HMailServer will let you select the IP to bind to though.