LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   SMTP Sendmail via Exchange (https://www.linuxquestions.org/questions/linux-server-73/smtp-sendmail-via-exchange-653009/)

FastForward 07-02-2008 03:27 AM

SMTP Sendmail via Exchange
 
Hi all,

Im a Windows admin by trade, trying to teach myself the dark arts of linux.

I have a sendmail box in domain A, which is currently using the ISP's SMTP gateway. Meanwhile in domain B, I have a MS Exchange SMTP gateway.

I really want to point my MX rec for domain A to the Exchange gateway, but before I jump in headfirst and make a mess of it, some advice would be appreciated! :)

Heres what I think I need to do:
- check DNS zones, and make sure I can ping hostnames mailserver.a.com from b.com and vice versa.
- change the MX rec to point to the Exchange gateway
- add b.com on exchange gateway as a protected domain
- edit sendmail.cf on mailserver.a.com, and change the Relay to exchange.
- restart the sendmail daemon and cross my fingers

Any ideas?

Cheers

chort 07-02-2008 08:47 AM

Being able to relay mail from a site is totally different than accepting mail going to a domain. If you point the MX record for domain A at your Exchange server, all the incoming mail for that domain is going to go to your Exchange server. Are you sure that's what you want to do?

Allowing domain A to relay outbound mail through Exchange is pretty simple. You just have to add it to the trusted relays, which is under the SMTP Virtual Server properties on Exchange. I forget the exact tabs to get there since I'm not in front of Exchange manager right this second... it should be pretty self-explanatory when you open up the Protocols folder, though.

FastForward 07-02-2008 03:16 PM

Thanks Chort. I really want to utilise the exchange gateway thats in place at domain b, and drop the isp alltogether that domain a uses, since they are both on the same WAN.

So I want to accept mail for domain A at exchange, and then forward it onto A using an SMTP connector or the like.

So the exchange side of it Im pretty sure I can handle, but I have never attempted this on linux/sendmail and want to make sure all I have to do is check DNS is operating correctly, and change the "Smart" relay host in sendmail.cf so exchange is the next hop.

Is there any where in the sendmail config that needs to be changed to allow incoming mail from exchange?

chort 07-02-2008 03:59 PM

For outbound mail you just have to set the smarthost to point to Exchange.

For inbound you shouldn't need to do anything different, as long as Exchange is delivering it to Sendmail with domain A as the address. If Sendmail was already configured to accept mail for that domain from anywhere, it won't care that it's coming from Exchange... Now if you had an access table setup in Sendmail to only accept mail from your ISP's server, then you'd need to change that to allow from Exchange instead, but it doesn't sound like that is the case.


All times are GMT -5. The time now is 12:02 PM.