1

Topic: smtp_fallback_relay per domain

==== Required information ====
- iRedMail version (check /etc/iredmail-release): 0.9.5.1
- Linux/BSD distribution name and version: Ubuntu 14.0.4
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): mySQL
- Web server (Apache or Nginx): Nginx
- Manage mail accounts with iRedAdmin-Pro? No
- Related log if you're reporting an issue:
====

Hi,

Is it possible with iRedMail to use smtp_fallback_relay on a per domain basis?

Example:

I have an existing domain with hundreds of active email addresses.   I created an MX record with priority 0, that points to the iRedMail server, which has some virtual users for DomainA.   

If a mail is sent to an address that doesn't exist in alias table, can it be forwarded with smtp_fallback_relat to another smtp host like smtp:[xxx.domain.com]??

I have tried to set the transport for the domain to smtp:[xxx.example.com], but this sends all mail to xxx.example.com, even the mail intended for the virutal users.

I have also set set in master.cf smtp_fallback_relay=[xxx.example.com] on the smtp entry. 

Thanks in advance for any advice you may have.

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: smtp_fallback_relay per domain

Didn't find setting for per-domain smtp_fallback_relay.
Curious, why it must be per-domain?

3 (edited by james23 2016-06-29 22:32:29)

Re: smtp_fallback_relay per domain

ZhangHuangbin wrote:

Didn't find setting for per-domain smtp_fallback_relay.
Curious, why it must be per-domain?

I will have a large number of domains that have the same setup:

Original: 100-1000 existing users
iRedmail: 100 virtual aliases, forwarding to various external domains (gmail, yahoo, others besides original domain)

iRedMail will be the primary mail server (MX 0).  If a virtual alias recipient is not found for this domain on the iRedMail server, I need to relay it back to the original mail server to handle delivery as it normally would.

Is there a way to achieve this without creating mailboxes for all of the existing users and setting their transport to the original SMTP server?

4

Re: smtp_fallback_relay per domain

james23 wrote:

iRedMail will be the primary mail server (MX 0).  If a virtual alias recipient is not found for this domain on the iRedMail server, I need to relay it back to the original mail server to handle delivery as it normally would.

I'm not sure whether the smtp_fallback_relay works this way. According to postfix document (http://www.postfix.org/postconf.5.html#smtp_fallback_relay ), it works if "SMTP destinations that can't be found or that are unreachable", not sure whether or not it will be triggered if user not found.

james23 wrote:

Is there a way to achieve this without creating mailboxes for all of the existing users and setting their transport to the original SMTP server?

No idea yet.

5

Re: smtp_fallback_relay per domain

I haven't found a way to do this.   I believe the only solution will be to create the users and set their transport to the original mail server unfortunately.    Thanks for taking the time to look into it for me.