Setting up Backup Mail

Hi

How do I setup sendmail to act as a backup mail server (store and forward) for an unlimited amount of domains.

1 Reply

In Debian and Fedora (and presumably Red Hat), the default sendmail.mc has the access database enabled. You can use this to add domains that you wish to relay; for each domain for which you wish to be a backup MX, go to the /etc/mail directory, and add a line of the form:

domain.example.com           RELAY

to the access file. Then leave your editor, and use make to build the database. While Debian's makefile will suggest you also do /etc/init.d/sendmail reload after running make, I've found that it's unnecessary in most cases.

The access database can also be used to deny relaying; if there's a zombie running a dictionary attack, you can nip it in the bud with something like:

Connect:192.168.42.42          REJECT

or

From:idiotspammer@example.com            550 Address unknown

More information is available here.

EDIT: pointing out the /etc/mail/access file.

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct