Backup Mail Server Questions

Matthew Seaman m.seaman at
Sun Sep 26 11:45:19 PDT 2004

On Sun, Sep 26, 2004 at 12:19:56PM -0500, Eric Crist wrote:

> I was wondering if anyone has any insight as to having a remote backup 
> mail server and the setup of such.  I'm currently using sendmail, and I 
> don't want to change that, so please don't recommend any of the other 
> servers out there. ;)
> One of my friends needs backup DNS/Mail in the even their connection 
> goes down.  How do I go about setting it up so that his user base 
> (about 80 users) will not see any problems in mail transmission and 
> reception if their primary servers go offline.  I would like mine to 
> automatically pickup the slack.
> Thanks for your replies!

Actually, it's pretty simple.  Starting with the more fundamental
things: to provide a backup DNS, configure a server to secondary for
your friends domains.  Under Bind9 that means something like this in

        zone "" {
            type slave;
            masters {
            file "s/";
            allow-query {
            allow-transfer {

If you want that to be available to the world in general (which you
usually do, for a mail server) then you need to get your friend to do
two things: add a NS record for your server to the ""
zone file and alter the registration of the domain so that your server
is listed as one of the registered name servers for the domain.  Your
friend should also check and make sure that his nameserver has
appropriate 'allow-transfer' statements so that your server can AXFR a
copy of the zone from it.

That's the hard part.  The Secondary MX'ing part is fairly easy.  All
you do is get your friend to add an MX record to the DNS
'' zone listing your server as a high numbered MXer:


    @       IN    MX   0

And then add:    RELAY

to /etc/mail/access and rebuild access.db.  That means your machine
will accept e-mails addressed to users and queue them
up for relaying onto to his servers as soon as they come back up
again.  If his site has to go down for an extended length of time, you
can make special arrangements to store incoming mail for longer than
the usual 5 days and then flush it over to him when he comes back up.

Recommended reading:

    The Bat Book:  Sendmail, Bryan Costales and Eric Allman, O'Reilly & Assoc. 
        3rd Ed. 2002.

    The Cricket Book: DNS and BIND, Paul Ablitz and Cricket Liu,
        O'Reilly & Assoc. 4th Ed. 2001.



Dr Matthew J Seaman MA, D.Phil.                       26 The Paddocks
                                                      Savill Way
PGP:         Marlow
Tel: +44 1628 476614                                  Bucks., SL7 1TH UK
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url :

More information about the freebsd-questions mailing list