[Problem] Sending Mails to groups with other nested groups does not work

Problem:
When sending a mail to a group with more than 1000 recipients (including recipients from nested groups!), the mail is not accepted/delivered.

Investigation:
/var/log/mail.log shows the following error if a mail is sent to the large group metagroup@customer.example.com:

Jun 26 12:46:52 mail01 postfix/cleanup[39851]: warning: 0DD472EDA83: unreasonable virtual_alias_maps map expansion size for metagroup@customer.example.com -- message not accepted, try again later

Explanation:
The maximal number of addresses that Postfix’ virtual alias expansion produces from each original recipient is by default 1000 which might be too low if nested groups are in use.

Solution:
Add the following line to /etc/postfix/main.cf.local:

virtual_alias_expansion_limit = 5000

and adjust 5000 to your needs. Afterwards restart Postfix: service postfix restart

keywords

limit, limits, mailserver, mails, postfix, mails

1 Like
Mastodon