I am currently setting up a new virtual private server with Debian Wheezy. I managed to install postfix, dovecot (IMAP) and MySQL.

Up to now, I can successfully login via SSL with an external mail client like Thunderbird or my Android Mail client and receive mails. Sending however does not work yet as I am getting this error when trying to send:

Nov 13 13:35:30 vmd3299 dovecot: auth-worker(7819): mysql( Connected to database mailserver
Nov 13 13:35:30 vmd3299 dovecot: imap-login: Login: user=<kontakt@mydomain.de>, method=PLAIN, rip=, lip=, mpid=7821, TLS, session=<1/JfMw7rqABtLADF>
Nov 13 13:35:42 vmd3299 postfix/smtpd[7822]: connect from ip-109-44-0-191.web.vodafone.de[]
Nov 13 13:35:43 vmd3299 postfix/smtpd[7822]: NOQUEUE: reject: RCPT from ip-109-44-0-191.web.vodafone.de[]: 554 5.7.1 <kontakt@mydomain.de>: Recipient address rejected: Access denied; from=<kontakt@mydomain.de> to=<kontakt@mydomain.de> proto=ESMTP helo=<[]>
Nov 13 13:35:43 vmd3299 postfix/smtpd[7822]: disconnect from ip-109-44-0-191.web.vodafone.de[]

As far as I can see, the TLS login seems to work, but that's it. I can't send mails to any recipient, neither to external recipients nor to local mail accounts on the same domain.

My exact versions are:

  • Postfix 2.9.6
  • Debian Wheezy (3.2.0-4-amd64 #1 SMP Debian 3.2.51-1 x86_64 GNU/Linux)

Here's my postfix main.cf:

#myorigin = /etc/mailname

smtpd_banner = $myhostname ESMTP $mail_name (Debian/GNU)
biff = no

# appending .domain is the MUA's job.
append_dot_mydomain = no

# Uncomment the next line to generate "delayed mail" warnings
#delay_warning_time = 4h

readme_directory = no

# TLS parameters
smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache
smtpd_recipient_restrictions = permit_sasl_authenticated, reject

# See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for
# information on enabling SSL in the smtp client.
myhostname = vmd3299.myhoster.net
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
myorigin = /etc/mailname
mydestination = vmd3299.myhoster.net, localhost.myhoster.net, localhost
relayhost =
mynetworks = [::ffff:]/104 [::1]/128
mailbox_size_limit = 0
recipient_delimiter = +
inet_interfaces = all
virtual_mailbox_domains = mysql:/etc/postfix/mysql-virtual-mailbox-domains.cf
virtual_mailbox_maps = mysql:/etc/postfix/mysql-virtual-mailbox-maps.cf
virtual_alias_maps = mysql:/etc/postfix/mysql-virtual-alias-maps.cf,mysql:/etc/postfix/mysql-email2email.cf
virtual_transport = dovecot
dovecot_destination_recipient_limit = 1

After hours of googling I reached the point where I don't know what to do now. Can anybody help me with this and maybe walk me through the last steps? I somehow have the feeling that there's just a tiny bit to be done here. Thanks in advance!


After changing this line:

smtpd_recipient_restrictions = permit_sasl_authenticated, reject

to that:

smtpd_recipient_restrictions =

I was able to send a test mail to myself, recpipient was the same user that sent the mail. Other existing external recipients are still rejected:

Nov 13 14:19:45 vmd3299 postfix/smtpd[8240]: NOQUEUE: reject: RCPT from ip-109-44-0-191.web.vodafone.de[]: 554 5.7.1 <ed.external@outside.com>: Relay access denied; from=<kontakt@mydomain.de> to=<eddie.external@outside.com> proto=ESMTP helo=<[]>


I resolved this issue by adding these two lines into /etc/postfic/main.cf

smtpd_sasl_type = dovecot
smtpd_sasl_path = private/auth

Now everything works fine with TLS and authentication.

Your Answer

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

Browse other questions tagged or ask your own question.