I'm trying to configure postfix and dovecot to connect to the same LDAP, and I kind of succeeded. But now, I have some discrepencies.

The reproduction is as:

  • I connect to dovecot in IMAP with thunderbird
  • I create an email from myself to send to myself
  • I use the postfix from the same server with the same user
  • I send the email

The results are:

  • The sent email is put in the Sent folder.
  • But I get no email in my inbox.

Checking on the server:

  • The sent email is in the /var/mail/<username>/.Sent/cur/ directory
  • The received email is in the /var/mail/<domain>/<username>/new/ directory

I thought I configured the maildir directory both the same way (as in /var/mail/%d/%n), but there must be a problem.

My configuration (external, sorry, couldn't make it in the question. And after 30h (still counting) on those damn configuration files, I'm not really sure which part might impact what…)


Do not deliver messages by postfix. Pass them to the dovecot's deliver instead.

See https://wiki.dovecot.org/LDA/Postfix for further information.

  • It's already the case, it uses dovecot-lmtp. But still, it's in the wrong directory, and I don't see, based on my configuration, why it is. – Dolanor Jan 22 '18 at 11:24

Keep home_mailbox = in the main.cf empty, and

smtpd_sasl_type = dovecot

smtpd_sasl_path = private/auth

and in dovecot conf

mail_home = /var/mail/%d/%n

mail_location = maildir:~

Also in dovecot conf you need to add or change this:

service auth {

    unix_listener /var/spool/postfix/private/auth { 
        mode = 0666
        #Change to the user and group of your postfix
        user = postfix  
        group = postfix

    unix_listener auth-userdb {
        mode = 0666
        #Change to the user and group of your postfix
        user = postfix
        group = postfix
    #dovecot user
    user = dovecot


service auth-worker {
  # Auth worker process is run as root by default, so that it can access
  # /etc/shadow. If this isn't necessary, the user should be changed to
  # $default_internal_user.
  user = root

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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