On Tuesday, January 20, 2009 at 11:23 CET, Goutam Baul <goutam.b...@cesc.co.in> wrote:
> On Tuesday.January 20,2009 Magnus Bäck wrote > > > Where have you made this definition? Two domains listed in > > mydestination by definition have the same set of localparts, i.e. > > I am giving below the portion of the main.cf to show the place where I > defined it: > virtual_mailbox_maps = ldap:accounts > accounts_timeout = 60 > accounts_server_host = 127.0.0.1 > accounts_search_base = ou=%d,dc=my,dc=organization > accounts_server_port = 389 > accounts_query_filter = (&(|(mail=%s) (mailAlternateAddress=%s)) > (accountStatus=active)) > accounts_result_attribute = mailMessageStore Okay, but since you allegedly list both domains in mydestination this will never be used. mydestination "wins" over virtual_mailbox_domains. Unless, of course, you've set local_transport = virtual. Anyway, time to see the "postconf -n" output. Note that your configuration method is obsolete (but still works). Prefer the newer way of putting the table configuration in a separate file. See ldap_table(5). > > Try again with the virtual mailbox domain and report back the > > problems you get. Your current design is simply broken unless it's > > feasible to use aliases to separate j...@example.com from > > j...@example.net -- the actual usernames could be joecom and joenet > > and the virtual alias table would resolve j...@example.com to joecom > > and j...@example.net to joenet. > > If I define the company1.com in the my destination and have > company2.com in the parameter virtual_mailbox_domains then mail for > company1.com gets delivered properly but those for company2.com gets > rejected. I get the following type of message in the maillog > Jan 20 15:17:39 mail postfix/virtual[1692]: 6E16F17E20: > to=<a...@company2.com>, relay=virtual, delay=0, status=bounced (unknown > user: "a...@company2.com") Then your virtual_mailbox_maps lookup doesn't work. Show the output of the following command: postmap -q a...@example.com ldap:accounts || echo Not found This command should return the path to the mailbox. (Please use example.com, example.net etc as example domains and not company2.com etc.) [...] -- Magnus Bäck mag...@dsek.lth.se