1

Topic: send unknown local recipient mail to relayhost

==== Required information ====
- iRedMail version (check /etc/iredmail-release):     v0.9.4
- Linux/BSD distribution name and version: Centos 7.2
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MYSQL
- Web server (Apache or Nginx): Apache
- Manage mail accounts with iRedAdmin-Pro? No
- Related log if you're reporting an issue:
====
Good morning,
      I configured Iredmail and postfix with relayhost, so all emails that are not destined to my domain using the external relayhost.

I would like to use the relayhost also when I send an email to a user who is not configured locally, for example info@xxxxxxxx.xx

I configured postfix with :
mydestination = $myhostname, localhost, localhost.localdomain, localhost.$mydomain

believing that it would send emails to info@xxxxxxx.xx to relayhost but instead I get the error:
May  3 10:33:58 iredmail-server postfix/pipe[13769]: CC9D95C870C: to=<info@xxxxxxx.xx>, relay=dovecot, delay=0.04, delays=0/0/0/0.03, dsn=5.1.1, status=bounced (user unknown)

Thank you
Mark

----

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

2

Re: send unknown local recipient mail to relayhost

The sample email address, info@xxxxxx.xx, is the domain xxxxxx.xx hosted on your server?

3

Re: send unknown local recipient mail to relayhost

Yes, xxxxxx.xx is the domain hosted on my Iredmail server, but user info@xxxxxx.xx doesn't exist.


ZhangHuangbin wrote:

The sample email address, info@xxxxxx.xx, is the domain xxxxxx.xx hosted on your server?

4

Re: send unknown local recipient mail to relayhost

If domain is hosted on your server, emails sent to all users under this domain should be delivered locally. Why you expect the email to be sent through relayhost?

5

Re: send unknown local recipient mail to relayhost

Because I need to forward the emails for user info@xxxxxx.xx to other users like mark@xxxxxx.xx, max@xxxxxx.xx, etc. so, if the mail goes to the relayhost, the server fetch it again and use dovecot/sieve to forward it.

Now I have added info@xxxxxx.xx in the DB table alias  and it works.

Alternatives ? Are there better solution ?

Thank you
Mark

ZhangHuangbin wrote:

If domain is hosted on your server, emails sent to all users under this domain should be delivered locally. Why you expect the email to be sent through relayhost?

6

Re: send unknown local recipient mail to relayhost

kaifamm wrote:

Alternatives ? Are there better solution ?

Solved by creating an mail alias is good enough, and probably the best.

7

Re: send unknown local recipient mail to relayhost

OK, thank you very much


ZhangHuangbin wrote:
kaifamm wrote:

Alternatives ? Are there better solution ?

Solved by creating an mail alias is good enough, and probably the best.