On Wed, Jan 21, 2009 at 05:11:58PM -0300, k bah wrote: > postfix-2.4.5 > cyrus-imapd-2.3.8 > -- > > I have Postfix configured to use LDAP, with Dovecot LDA. I was told Postfix > is the one who decides what is the mailbox name.
The email address, not the filename, when using an external LDA. It is up to the dovecot LDA to map the recipient email address to a file name. > Dovecot LDA saves the message on the mailbox with name as specified > by Postfix. See above. > The same should be true when using lmtp and Cyrus, as I was told on > another list. Yes, the LMTP server maps the mailbox email address to a suitable storage location. > My user entries on LDAP follow this format: > > mail= usern...@domain.org > uid = username~domain.org > mailRoutingAddress= username~domain....@domain.org > > I started some of Postfix daemons (master.cf) with "-v" and noticed, > when using Dovecot LDA, the correct mapping mail -> mailroutingaddress > happens (usern...@domain.org -> username~domain....@domain.org, so > Dovecot LDA saves the message to the mailbox username~domain.org) Addresses rewriting before delivery is controlled via virtual_alias_maps, address rewriting during delivery is only available in the local(8) delivery agent via alias_maps. If the dovecot LDA is plugged in via mailbox_transport, you must do the same with Cyrus LMTP or you lose local alias expansion. > The same does not happen when using cyrus lmtp instead of dovecot lda. You must be using virtual_transport instead and making the domain a virtual_mailbox_domain or something similar involing transport overrides. > alias_maps = hash:/etc/aliases, ldap:ldapmycompany > local_recipient_maps = hash:/etc/aliases, ldap:ldapmycompany > virtual_alias_maps = hash:/etc/postfix/virtual > virtual_alias_domains = hash:/etc/postfix/virtual > virtual_maps = ldap:/etc/postfix/ldap-mycompany.cf (ldap-mycompany.cf has the > same stuff defined here on ldapmycompany_* The virtual_maps setting has no effect when virtual_alias_maps is also defined. > mailbox_transport = lmtp:unix:/var/lib/imap/socket/lmtp (when using cyrus) > > OR > > dovecot_destination_recipient_limit = 1 (when using dovecot) > mailbox_transport = dovecot This looks correct. > transport: -- (just when using cyrus/lmtp) > > domain.org lmtp:unix:/var/lib/imap/socket/lmtp There's your problem, don't do this. -- Viktor. Disclaimer: off-list followups get on-list replies or get ignored. Please do not ignore the "Reply-To" header. To unsubscribe from the postfix-users list, visit http://www.postfix.org/lists.html or click the link below: <mailto:majord...@postfix.org?body=unsubscribe%20postfix-users> If my response solves your problem, the best way to thank me is to not send an "it worked, thanks" follow-up. If you must respond, please put "It worked, thanks" in the "Subject" so I can delete these quickly.