Mike Scott <com> wrote:
Are you sure this will do what you want? Other SMTP servers will likely queue
the mail to try again, but MTAs that try to send mail may harass the user
about the "unavailable" server. You'd want to test this out with your
supported mail clients...
A better solution is likely to run two mailservers, both exim (or whatever),
with one just forwarding all mail to the other. Both get listed as MX
servers, with the main one as a higher priority. When doing maintenance, just
take the main server offline. Clients who can't connect will just use the
other server. When it's back online, the other server will deliver the mail
to the primary and life is good.
They can be on the same machine if you use 2 network addresses, but using a
seperate machine as a backup MX lets you do real maintenance on the first
which includes actual server (as opposed to service) downtime.
What kind of crazy maintenance procedure do you have that you need to down the
process for any period of time, but don't mind keeping the machine online and
If you absolutely must do this crazy thing, any unix network programming book
should have an example of a server that handles multiple connections. If
you're using Perl, the camel book has an example in the Sockets section of the
IPC chapter which you can start with.
Mark Rafn net <http://www.dagon.net/>