OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
 
RE: 2 MTAs with different users for the same domain

Victor.Duchovnimorganstanley.com
Date: Mon Jun 09 2003 - 08:01:43 CDT


On Mon, 9 Jun 2003, Roman Medina wrote:

> > On smtp1.mydomain.com:
> > fallback_transport = smtp:[smtp2.mydomain.com]
> >
> > and on smtp2.mydomain.com:
> > fallback_transport = smtp:[smtp1.mydomain.com]
>
> Is it really as simple as that? How are loops avoided? (imagine a
> non-existant user in both smtp-servers: if smtp1 receive such a mail, it
> will be forwarded to smtp2, which would forward it again to smtp1... or
> not?). Am I missing any point?
>

Ralf's scenario works if each machine delivers mail to local unix users,
and only knows about (lists in /etc/passwd or equivalent) users for which
it performs local delivery.

If each machine has the complete user list in /etc/passwd, use aliases to
direct each users mail to the right machine.

Make sure that on both machines:

        # This is the default
        myorigin = $myhostname

        # Accept mail for the domain
        mydestination = $myhostname, localhost.$mydomain, $mydomain

        # Alias users to appropriate mailboxes:
        alias_maps = hash:/etc/postfix/aliases
        alias_database = hash:/etc/postfix/aliases

/etc/postfix/aliases
# On the RHS use the $myhostname value for each machine
#
user1: user1machine1.dom.ain
user2: user2machine2.dom.ain
...

--
        Viktor.