在執行 HELO 握手時失去與 mx.servername 的連接
我是管理郵件伺服器的新手,所以當郵件伺服器可以發送到某些電子郵件(如 gmail、telus 和 shaw)但不能發送到其他電子郵件地址時,我會不知所措。我猜只是具體的。這是郵件日誌中的一個範例:
<info@dockyardsliving.ca>, relay=mx.dockyardsliving.ca[65.254.254.50]:25, delay=67513, delays=67512/0.01/0.35/0, dsn=4.4.2, status=deferred (lost connection with mx.dockyardsliving.ca[65.254.254.50] while performing the HELO handshake)
這裡也是我的 main.cf 文件:
smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu) biff = no append_dot_mydomain = no readme_directory = no smtpd_tls_cert_file = /etc/ssl/certs/mailserver.pem smtpd_tls_key_file = /etc/ssl/private/mailserver.pem smtpd_use_tls=yes smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache # information on enabling SSL in the smtp client. smtpd_relay_restrictions = permit_mynetworks permit_sasl_authenticated defer_unauth_destination myhostname = localhost alias_maps = hash:/etc/aliases alias_database = hash:/etc/aliases mydestination = localhost, localhost.localdomain, , localhost relayhost = mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128 mailbox_size_limit = 0 recipient_delimiter = + inet_interfaces = all virtual_transport = dovecot dovecot_destination_recipient_limit = 1 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 smtpd_sasl_type = dovecot smtpd_sasl_path = private/auth smtpd_sasl_auth_enable = yes smtpd_tls_security_level = may smtpd_tls_auth_only = yes smtpd_recipient_restrictions = permit_mynetworks permit_sasl_authenticated reject_unauth_destination
知道為什麼我可以發送到某些電子郵件而不能發送到其他電子郵件嗎?有什麼看起來不正常的嗎?
更新
好的,所以我改變了
myhostname = mail.website.com
並重新啟動了 postfix 服務,但我現在無法接收電子郵件,所以我嘗試了一下
myhostname = website.com
,結果還是一樣。所以我現在只是回到本地主機。更新
所以它現在有效。檢查了日誌,電子郵件在該位置被接受。必須將下面的行添加到 main.cf
smtp_helo_name = mail.website.com
謝謝
一些郵件伺服器對你如何問候他們非常嚴格,例如他們可以:
Reject connections where the domain provided at HELO and EHLO has neither an 'A' nor an 'MX' record in DNS
或者
Reject the request when the HELO or EHLO hostname is not in fully-qualified domain or address literal form, as required by the RFC
smtp_helo_name預設為$myhostname(在您的 main.cf 中設置為 localhost),因此您可以嘗試將其設置為正確的 host.example.com
遠端伺服器給5??問候並關閉連接。
我的comp中“telnet測試”的結果(IP地址被屏蔽):
telnet mx.dockyardsliving.ca smtp Trying 65.254.254.51... Connected to mx.dockyardsliving.ca. Escape character is '^]'. 554 impinc04.yourhostingaccount.com NO UCE error: R6.1: aaa.bbb.ccc.ddd is on the Spamhaus blacklist. Please visit: http://www.spamhaus.org Connection closed by foreign host.
自己在主機上 Telnet smtp 埠獲取主機的原因。