Operating System - HP-UX
1829962 Members
2124 Online
109998 Solutions
New Discussion

sendmail and multi-homed systems

 
David Rodman
Frequent Advisor

sendmail and multi-homed systems

If I have a system with multiple interfaces how does sendmail choose the
interface to use (assuming 2 interfaces can reach the target address). I would
like to force sendmail to use one of them for delivery. Logically like this:

If delivery to user@target.knowndomain then
Use InterfaceY
Else
Use InterfaceZ

I have looked in the sendmail.cf but not found anything that looks right.
Any suggestions?

4 REPLIES 4
Rick Garland
Honored Contributor

Re: sendmail and multi-homed systems

Which IP, or hostname is sendmail set to go to?
This can probably be found in the DNS info with the MX records.


CHRIS_ANORUO
Honored Contributor

Re: sendmail and multi-homed systems

If you have sendmail 8.9.3 (PHNE_18979)installed, copy /usr/newconfig/etc/nsswitch.conf to /etc/.

Cheers!
When We Seek To Discover The Best In Others, We Somehow Bring Out The Best In Ourselves.
Kofi ARTHIABAH
Honored Contributor

Re: sendmail and multi-homed systems

I guess there are two issues here:
1. what path your mail (application level) travels; or
2. what path the packets (IP layer)

For outbound mail, sendmail (application layer) attempts to deliver directly to the destination domain's mailserver as specified by MX record - if there is no MX record, sendmail relies on a relay entry in your /etc/mail/sendmail.cf to determine which server will relay on its behalf.

For the IP layer, depending on what routing (netstat -rn to check) you have set up, the packets will travel on one interface or the other - usually unless there is an explict route to the relay machine, the default route will be used.

nothing wrong with me that a few lines of code cannot fix!
Kofi ARTHIABAH
Honored Contributor

Re: sendmail and multi-homed systems

For inbound mail, the server listens on both interfaces but you have to configure the MX record entries on your DNS to point to the appropriate interface... by the way, it is automatic (if your MX records are properly setup)
nothing wrong with me that a few lines of code cannot fix!