On 6/3/2014 3:50 PM, Peter Bittner wrote: > Hi, > > I'm trying to find out which is the correct way to configure alias > domains on postfix. > > For example, I have 3 different domains (example.com, example.info, > example.net), and when I send an e-mail to a user on any of the three > domains it's always sent to "u...@example.com". > In other words, I never need to configure mailboxes or users on any of > the other two domains ("alias domains", as I call them). It's > sufficient to have the user configured on the main domain. > > I've seen the following resources on that topic: > - https://workaround.org/ispmail/wheezy/virtual-domains > - http://www.postfix.org/VIRTUAL_README.html#forwarding > > Unfortunately, those resources only describe the following types of > forwarding: > - j...@example.info --> jane@somewhere-else > - @example.info --> jim@somewhere-else (catch-all feature) > > What I would need is a correctly working solution of: > - @example.info --> @somewhere-else, or > - <any>@example.info --> <any>@somewhere-else > > Doing some tests with some test configuration > sending/forwarding/retrieving seems to work (e-mails sent to one of > the alias domains arrive at the main domain), but if there is a > non-existing mailbox on the main domain and the e-mail is sent to the > corresponding user at one of the alias domains no e-mail bounces back > from the main domain saying that the mail could not be delivered. > > How can I make postfix bounce e-mails back when there is no user for > it on the main domain? Is there a specific, standard way of doing > alias domains on postfix? (It should be some kind of "standard > use-case" after all, shouldn't it? Google Mail let you define alias > domains on Google Apps, and that simply works.) > > Thanks in advance for any hints, > Peter >
If your mail is delivered locally to standard system users, you can just add all the domains to mydestination and it just works; no alias mapping needed, all users appear in all domains. If the domains are virtual, you need to use 1-1 address mapping. Do not use wildcard domain mapping, as wildcards defeat the automatic recipient validation of postfix. -- Noel Jones