Goran Blazic <[EMAIL PROTECTED]> writes on 2 October 2000 at 11:32:03 +0200
 > I have this problem I dont even know how to start solving...
 > 
 > There is this mail server for a company that is online most of the time
 > (18-20 hours a day), but it can happen, that the server goes offline for
 > some period (dont ask, I tried, but they dont want to change it!).
 > Ok, I thought, so I put that server as the primary MX, and put another as a
 > lower priority MX...

Well, first, why bother?  Normally a sender will retry for 3 days
before they give up; if the system is only down hours at a time, you
may be doing nobody any favors by setting up a secondary MX.

 > As far as I understand this, any mail server that want to send mail to the
 > primary MX will do so, if that server is available. If not, it will use a
 > lower priority one.... Correct?
 > Ok, but how do I get the lower priority mail server to send mail to the
 > primary one when he comes online? My guess is that something like smptget*
 > (whatever) is not really a sollution...

If you decide a secondary MX *is* what you need, what I did is have
all the mail for the primary delivered into a maildir, and then use
maildirsmtp to deliver it when the time is right.  In my case, I
simply have cron try every 10 minutes.  You could do something even
simpler, put in smtproutes a forced route to the primary for all the
domains that belong there, and the messages will just sit in the queue
on the secondary.  I chose the maildir route to give me more control
on how long they were held, and when exactly they were delivered (I
can cancel the cron action before I bring the primary back up, for
example, if I want to work on it a bit before delivering the mail). 

In my experience, some very small percentage of the mail will end up
at the secondary MX in normal operation (probably because of local
network and DNS situations), so you shouldn't pick a technique that
requires manual intervention to deliver the mail (or you need to check
every hour or so for accumulated mail, and trigger delivery if there
is some).
-- 
David Dyer-Bennet / Welcome to the future! / [EMAIL PROTECTED]
Photos: http://dd-b.lighthunters.net/ 
SF: http://www.dd-b.net/dd-b/ Minicon: http://www.mnstf.org/minicon/

Reply via email to