Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I set up a mail server AD + Postfix + Dovecot + Kerberos

This works fine for only one domain In the attribute, in,

Config files:


server_host = server
search_base = dc=cn,dc=energy
version = 3
bind = yes
bind_dn =
bind_pw = passwd

query_filter = (&(objectCategory=person)(|(mail=%s)(otherMailbox=%s))(!(userAccountControl=514)))
result_attribute = mail otherMailbox
result_format = %d/%u


hosts = server:3268
debug_level = 2
dn = ldapmail
dnpass = passwd
tls = no
auth_bind = yes
auth_bind_userdn =\%u
ldap_version = 3
base = dc=cn, dc=energy
deref = searching
scope = subtree
user_attrs = mail=user,uid=vmail, gid=vmail
user_filter = (&(objectclass=person)(|(sAMAccountName=%n)(otherMailbox=%n))(!(userAccountControl=514)))
default_pass_scheme = CRYPT


attribute mail

postmap -q ldap:/etc/postfix/,,

attribute otherMailbox

postmap -q ldap:/etc/postfix/,,

The filter searches and finds the correct. Just does not work result_format ???


this name one directory ! hmmm dovecot dont find it

Many thanks for your help.

share|improve this question
Can you please specify your question? What's your problem exactly? – sebokopter Jun 3 '11 at 1:10

Is your problem that your postfix ldap query works but your dovecot ldap query doesn't?

Then you probably take a closer look at your mapping of the user_attrs in the dovecot-ldap.conf. You specifiy in the user_attrs ldap-attribute = dovecot-attribute. There might be something wrong here because dovecot doesn't know an attribute named vmail 1,2. See: and

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.