1

Topic: per user alias not working

==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release): 1.3.1 PGSQL Edition
- Deployed with iRedMail Easy or the downloadable installer? installer
- Linux/BSD distribution name and version:  Ubuntu 18.04.4 LTS
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): PGSQL
- Web server (Apache or Nginx): Nginx
- Manage mail accounts with iRedAdmin-Pro? No
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====

I've followed instruction here:

https://docs.iredmail.org/sql.create.mail.alias.html
https://docs.iredmail.org/user.alias.address.html

SELECT * FROM alias
SELECT * FROM forwarding
...show relevant alias, emails, domains and correct settings.

I've tried restarting POSTFIX service.

Email is successfully delivered from external email to primary iredmail email account.
When sending to email alias from external email, nothing arrives at iredmail email account.

----

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

2

Re: per user alias not working

You can try to query alias address like this:

cd /etc/postfix/mysql/
for cf in $(ls *.cf); do echo $cf; postmap -q "<your-alias-address>" mysql:./$cf; done

If your alias was correctly added, it should print it on console. Please copy the FULL console output here for troubleshooting.

3

Re: per user alias not working

Does this work for iRedMail Free version, or aliases only work for Pro version?

4 (edited by zippydan 2021-02-19 16:12:25)

Re: per user alias not working

ZhangHuangbin wrote:
cd /etc/postfix/mysql/
for cf in $(ls *.cf); do echo $cf; postmap -q "<your-alias-address>" mysql:./$cf; done

I'm using postgres, so I used the command you supplied above but changed "mysql" to "pgsql".

ZhangHuangbin wrote:

If your alias was correctly added, it should print it on console. Please copy the FULL console output here for troubleshooting.

Output below:

[root@sv-remote-iredmail:/etc/postfix/pgsql# for cf in $(ls *.cf); do echo $cf; postmap -q "alias1@domain2.com" pgsql:./$cf; done
catchall_maps.cf
domain_alias_catchall_maps.cf
domain_alias_maps.cf
recipient_bcc_maps_domain.cf
recipient_bcc_maps_user.cf
relay_domains.cf
sender_bcc_maps_domain.cf
sender_bcc_maps_user.cf
sender_dependent_relayhost_maps.cf
sender_login_maps.cf
transport_maps_domain.cf
transport_maps_maillist.cf
transport_maps_user.cf
virtual_alias_maps.cf
alias1@domain2.com
virtual_mailbox_domains.cf
virtual_mailbox_maps.cf

5

Re: per user alias not working

Ignore this.

It seems to be working.