Postfix - do not list domain example.com in BOTH mydestination and virtual_mailbox_domains

Want to support HowtoForge? Become a subscriber!
 
Submitted by falko (Contact Author) (Forums) on Tue, 2011-08-09 11:11. :: Errors

Error: Postfix - do not list domain example.com in BOTH mydestination and virtual_mailbox_domains

You see the following error in your mail log:

Feb 24 21:42:39 mail postfix/trivial-rewrite[1896]: warning: do not list domain example.com in BOTH mydestination and virtual_mailbox_domains

 

Solution

You have example.com in the resource (for example a MySQL database) referenced in the virtual_mailbox_domains directive in /etc/postfix/main.cf AND in the mydestination line (also in /etc/postfix/main.cf)! This doesn't work. You can list example.com either in virtual_mailbox_domains or in mydestination, but not in both.

Please correct this and restart Postfix:

/etc/init.d/postfix restart


Please do not use the comment function to ask for help! If you need help, please use our forum.
Comments will be published after administrator approval.
Submitted by Christopher Thomas (not registered) on Mon, 2012-07-23 18:40.
you mention that to solve the problem, you need to make both different, but never went far enough, nobody knows how to fix the problem, just that there is a problem. the error message already explained the problem, therefore in order to be a "howto" we need to know "howto" fix it.
Submitted by Anonymous (not registered) on Fri, 2013-12-06 07:46.
In my case, at least, removing mydomain.com from mydestination cleared things up. On my server, mydestination is just localhost, localhost.localdomain
Submitted by Anonymous (not registered) on Wed, 2014-07-16 21:27.
GREAT SOLUTION, works for me.
Submitted by Nilpo (registered user) on Thu, 2013-12-05 07:00.
That would depend on how the server is set up.  There is no one-size-fits all solution.  It's different for every configuration.