A
A
Alexander Semenenko2017-11-27 14:17:34
linux
Alexander Semenenko, 2017-11-27 14:17:34

How to set up postfix as a relay to an external server?

There is an external mail server. On which there are about 30 accounts. There is postfix on the local network, through which we want to run all letters.
Everything was already working, but the external server changed, it became kerio, the port became: 465. Was :587.
Now this error:
postfix/qmgr[939]: 61EB88018: from=, size=1632, nrcpt=2 (queue active)
postfix/smtp[1020]: warning: SASL authentication failure: No worthy mechs found
postfix/smtp[1020] : 61EB88018: to=, relay=xxxxx[xxxxx]:465, delay=354, delays=354/0.01/0.09/0, dsn=4.7.0, status=deferred (SASL authentication failed; cannot authenticate to server xxxx[xxxxxx ]: no mechanism available)
Here is my main.cf

spoiler

# See /usr/share/postfix/main.cf.dist for a commented, more complete version
smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)
biff = no
append_dot_mydomain = no
readme_directory = no
smtpd_tls_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem
smtpd_tls_key_file=/etc/ssl/private/ssl-cert-snakeoil.key
smtpd_use_tls=yes
smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache
smtp_tls_wrappermode = yes
smtp_tls_security_level = encrypt
smtpd_tls_security_level = may
smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated defer_unauth_destination
myhostname = mailproxy
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
mydestination = mailproxy, localhost, localhost.localdomain
mynetworks = 10.30.201.0/24
mailbox_size_limit = 0
recipient_delimiter = +
inet_interfaces = all
inet_protocols = all
relayhost = [xxx]:465
smtp_sender_dependent_authentication = yes
sender_dependent_relayhost_maps = hash:/etc/postfix/sender_relay
smtp_sasl_auth_enable = yes
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtp_sasl_security_options = noanonymous
smtp_tls_CAfile = /etc/postfix/cacert.pem
smtp_use_tls = yes
message_size_limit = 62914560

/etc/postfix/sender_relay - here, respectively, mappings mappings of local accounts and what to send through
/etc/postfix/sasl_passwd - here logins, passwords
Tried to add options, but did not help:
smtp_tls_wrappermode = yes
smtp_tls_security_level = encrypt
smtpd_tls_security_level = may
Directly using smtp and imap the client clings, i.e. the password is correct.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Andrew, 2017-12-12
@Brujerizmo

In master .cf
-o smtpd_sasl_auth_enable=yes

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question