Postfix 尝试发送邮件时超时

Postfix 尝试发送邮件时超时

我刚刚在 CentOS VPS 上安装了 Dovecot 和 Postfix,现在正在尝试让它们工作。接收邮件工作正常,在 Windows 上使用 Thunderbird 获取邮箱(使用 SASL 进行身份验证)也正常,但是当我尝试发送邮件(再次使用 Thunderbird)时,它几乎立即出现一条有关 SMTP 连接超时的消息。如果我尝试其他端口(除了用于 SSL/TLS 安全连接的 465 之外),则需要更长时间但仍然会超时(所以我认为端口是正确的,但有些东西拒绝了我的连接)。

的结果postfix -n

alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases
body_checks = regexp:/etc/postfix/body_checks
broken_sasl_auth_clients = yes
command_directory = /usr/sbin
config_directory = /etc/postfix
daemon_directory = /usr/libexec/postfix
debug_peer_level = 2
disable_dns_lookups = no
header_checks = regexp:/etc/postfix/header_checks
home_mailbox = Maildir/
html_directory = no
inet_interfaces = all
mail_owner = postfix
mailq_path = /usr/bin/mailq.postfix
manpage_directory = /usr/share/man
message_size_limit = 104857600
mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain
mydomain = miikkavirtanen.net
myhostname = miikkavirtanen.net
mynetworks = 192.168.0.0/24, 127.0.0.0/8, 10.0.0.0/24
myorigin = $mydomain
newaliases_path = /usr/bin/newaliases.postfix
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix-2.3.3/README_FILES
relay_domains =
sample_directory = /usr/share/doc/postfix-2.3.3/samples
sendmail_path = /usr/sbin/sendmail.postfix
setgid_group = postdrop
smtpd_banner = $myhostname ESMTP
smtpd_client_restrictions = permit_mynetworks,reject_unknown_client,permit
smtpd_recipient_restrictions = permit_mynetworks,permit_auth_destination,permit_sasl_authenticated,reject
smtpd_sasl_auth_enable = yes
smtpd_sasl_local_domain = $myhostname
smtpd_sasl_path = private/auth
smtpd_sasl_security_options = noanonymous
smtpd_sasl_type = dovecot
smtpd_tls_cert_file = /etc/pki/tls/certs/server.crt
smtpd_tls_key_file = /etc/pki/tls/certs/server.key
smtpd_tls_session_cache_database = btree:/var/lib/postfix/smtpd_scache
smtpd_use_tls = yes
unknown_local_recipient_reject_code = 550

答案1

下意识的反应:检查(使用 telnet)您的 ISP 是否没有阻止传出邮件端口(25 和 465)。

确保您的防火墙允许到 TCP 端口 25 和 465 的传出连接。

相关内容