On Mon, Jun 24, 2013 at 09:54:55AM -0700, Scott Vanderbilt wrote:
> I'm having difficulties configuring smtpd as a backup mail server.
> smtpd is running on my main mail server and works a treat. (Good
> riddance, sendmail.)
> 
> I've read the man pages and understood them the best I can, and
> tried various configuration options, all to no avail. Mails to known
> valid users on the backup server continue to be rejected with 550
> responses. The goal, of course, is for this backup server to accept
> these mails and relay them to the main mail server host.
> 
> This is on 5.3-current with smtpd 5.3.3.
> 
> Here is my smtp.conf (in its entirety):
> 
>    listen on all
> 
>    table aliases db:/etc/mail/aliases.db
>    table domains file:/etc/mail/domains
>    table secrets db:/etc/mail/secrets.db
> 
>    # Relay to main mail server via TLS
>    accept for domain <domains> relay via \
>         tls+auth://f...@smtp.datagenic.com auth <secrets>
> 
>    accept for local alias <aliases> deliver to mbox
>   debug: smtpd: offline scanning done
>   debug: smtp: new client on listener: 0x81a09170
>   smtp-in: New session 000000004aa75c26 from host
> mail-la0-f48.google.com [209.85.215.48]
>   smtp-in: Failed command on session 000000004aa75c26: "RCPT
> TO:<geo...@datagenic.com>" => 550 Invalid recipient
>   smtp-in: Closing session 000000004aa75c26
>   debug: smtp: 0x85d02000: deleting session: done
> 
> In this case, the recipient 'george' is a local user on the backup
> server host. I cannot understand why the mail has been rejected in
> this case.

It is rejected because your accept rules match local mails only.
You need to specify 'accept from any' to receive mail from the outside.

> I've also tried various options using 'relay backup' without
> success. The man page does not give an example for backup servers.
> So, I'm not sure how to proceed.

"relay backup" is used to setup secondary mail servers for a domain,
that is a server that accept mails for a domain and relay to MXs with
higher priority (i.e. lower preference in DNS).

> Many thanks in advance for any guidance you can offer.

You're welcome.

Eric.

Reply via email to