Boston Linux & Unix (BLU) Home | Calendar | Mail Lists | List Archives | Desktop SIG | Hardware Hacking SIG
Wiki | Flickr | PicasaWeb | Video | Maps & Directions | Installfests | Keysignings
Linux Cafe | Meeting Notes | Blog | Linux Links | Bling | About BLU

BLU Discuss list archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

postfix config

Bill Holt wrote:
>Matthew Valites writes:
>>If you just want to make sure that mail gets delivered when your primary 
>>mail server goes down, you should set up the secondary server as a 
>>backup MX.
> ...the outside world will be accessing my mail gateway via the MX record. 
> The gateway will process incoming mail for spam, then relay it to the server
> listed in the transport file.
> Now the question was and is, is it that the transport file only allows 
> a one to one mapping (example.domain smtp: or a one to many mapping
> ( smtp:, or something different....

I believe it is one-to-one, or via a regular expression map, 
many-to-one, though for a definitive answer, post your question to the 
Postfix users mailing list. Even if the syntax supported it, I wouldn't 
necessarily expect the end result to be MX-like behavior. It might, for 
example, just pick one of the two destinations at random, just as a 
multi-homed host is treated, or MX records with equivalent preferences. 
(Remember, you need a mechanism to specify priority.)

As Matthew Valites points out, an MX record is the behavior you are 
seeking. Just because your Exchange servers are internal to your network 
doesn't mean you can't use an MX record. In your transport file just list:

and then setup either:

exchange	MX	10
exchange	MX	20
exch1		A
exch2		A

on the internal side of a "split horizon" DNS setup, or create a 
subdomain, with a corresponding internal content server.

If you really want to avoid using DNS, you might be able to hack 
together the equivalent behavior by using the relayhost mechanism
( instead of a 
transport table entry, and then use fallback_relay 
( to specify the 
backup Exchange server. Though this is a contortion of what relayhost 
was intended for (you'd have to adjust other directives so the gateway 
doesn't think mail for is local) and if you use this gateway 
to relay outbound mail, I think it'll break.


BLU is a member of BostonUserGroups
BLU is a member of BostonUserGroups
We also thank MIT for the use of their facilities.

Valid HTML 4.01! Valid CSS!

Boston Linux & Unix /