Email

Exim 郵件伺服器通過 SMTP 發送速度慢

  • June 15, 2013

伺服器向我發送橫幅大約需要 30 秒,但初始連接會立即完成

只有當我在辦公室時才會發生,在家裡它工作正常

在辦公室,我為我的客戶端 IP 設置了一個 rRns,但它不起作用。

伺服器:Exim,公共固定 IP,rDNS,無埠阻塞,在數據中心


配置:

hostlist loopback = <; 127.0.0.0/8 ; 0.0.0.0 ; ::1 ; 0000:0000:0000:0000:0000:ffff:7f00:0000/8
hostlist senderverifybypass_hosts = net-iplsearch;/etc/senderverifybypasshosts
hostlist skipsmtpcheck_hosts = net-iplsearch;/etc/skipsmtpcheckhosts
hostlist spammeripblocks = net-iplsearch;/etc/spammeripblocks
hostlist backupmx_hosts = lsearch;/etc/backupmxhosts
hostlist trustedmailhosts = lsearch;/etc/trustedmailhosts
domainlist user_domains = ${if exists{/etc/userdomains} {lsearch;/etc/userdomains} fail}

這在伺服器上發生得非常快:

30132 ident connection to 89.238.207.49 failed: Connection refused
30132 sender_fullhost = [89.238.207.49]
30132 sender_rcvhost = [89.238.207.49]
30132 Process 30132 is handling incoming connection from [89.238.207.49]    
30132 host in host_lookup? no (option unset)
30132 set_process_info: 30132 handling incoming connection from [89.238.207.49]
30132 host in host_reject_connection? no (option unset)
30132 host in sender_unqualified_hosts? no (option unset)
30132 host in recipient_unqualified_hosts? no (option unset)
30132 host in helo_verify_hosts? no (option unset)
30132 host in helo_try_verify_hosts? no (option unset)
30132 host in helo_accept_junk_hosts? yes (matched "*")
30132 using ACL "acl_connect"
30132 processing "accept"
30132 check hosts = +trustedmailhosts
30132 sender host name required, to match against lsearch;/etc/trustedmailhosts
30132 looking up host name for 89.238.207.49
30132 IP address lookup yielded relay.easycomm.ro

客戶端

2011.09.14 13:08:13 SMTP (mail.server.ro): Begin execution
2011.09.14 13:08:13 SMTP (mail.server.ro): Port: 465, Secure: SSL, SPA: no
2011.09.14 13:08:13 SMTP (mail.server.ro): Finding host
2011.09.14 13:08:13 SMTP (mail.server.ro): Connecting to host
2011.09.14 13:08:13 SMTP (mail.server.ro): Securing connection
2011.09.14 13:08:13 SMTP (mail.server.ro): Connected to host
---> This is a 1 minute 5 seconds gap
2011.09.14 13:09:18 SMTP (mail.server.ro): <rx> 220-genius.filipnet.ro ESMTP Exim     4.69 #1 Wed, 14 Sep 2011 13:09:26 +0300 
2011.09.14 13:09:18 SMTP (mail.server.ro): <rx> 220-We do not authorize the use of     this system to transport unsolicited, 
2011.09.14 13:09:18 SMTP (mail.server.ro): <rx> 220 and/or bulk e-mail.
2011.09.14 13:09:18 SMTP (mail.server.ro): [tx] EHLO CatalinDell
2011.09.14 13:09:18 SMTP (mail.server.ro): <rx> 250-genius.filipnet.ro Hello     CatalinDell [89.238.207.49]
2011.09.14 13:09:18 SMTP (mail.server.ro): <rx> 250-SIZE 52428800
2011.09.14 13:09:18 SMTP (mail.server.ro): <rx> 250-PIPELINING
2011.09.14 13:09:18 SMTP (mail.server.ro): <rx> 250-AUTH PLAIN LOGIN
2011.09.14 13:09:18 SMTP (mail.server.ro): <rx> 250 HELP
2011.09.14 13:09:18 SMTP (mail.server.ro): Authorizing to server
2011.09.14 13:09:18 SMTP (mail.server.ro): [tx] AUTH LOGIN
2011.09.14 13:09:18 SMTP (mail.server.ro): <rx> 334 VXNlcm5hbWU6
2011.09.14 13:09:18 SMTP (mail.server.ro): [tx] dGVzdEBzcG9ydGd1cnUucm8=
2011.09.14 13:09:18 SMTP (mail.server.ro): <rx> 334 UGFzc3dvcmQ6
2011.09.14 13:09:18 SMTP (mail.server.ro): [tx] *****
2011.09.14 13:09:18 SMTP (mail.server.ro): <rx> 235 Authentication succeeded
2011.09.14 13:09:18 SMTP (mail.server.ro): Authorized to host
2011.09.14 13:09:18 SMTP (mail.server.ro): Connected to host
2011.09.14 13:09:18 SMTP (mail.server.ro): [tx] MAIL FROM: <*****>
2011.09.14 13:09:18 SMTP (mail.server.ro): <rx> 250 OK
2011.09.14 13:09:18 SMTP (mail.server.ro): [tx] RCPT TO: <*****>
2011.09.14 13:09:18 SMTP (mail.server.ro): <rx> 250 Accepted
2011.09.14 13:09:18 SMTP (mail.server.ro): [tx] DATA
2011.09.14 13:09:18 SMTP (mail.server.ro): <rx> 354 Enter message, ending with "."     on a line by itself
2011.09.14 13:09:18 SMTP (mail.server.ro): [tx] .
---> This is a 1 minute 10 seconds gap
2011.09.14 13:10:28 SMTP (mail.server.ro): <rx> 250 OK id=1R3mPG-0004T4-7Q
2011.09.14 13:10:28 SMTP (mail.server.ro): End execution

— 初始資訊

我在 Windows 7 附帶的“Windows Live Mail”上設置了一個電子郵件帳戶

接收速度非常快,但由於某種原因發送速度非常慢,我不得不將傳出超時時間增加到 3 分鐘以使其正常工作。

伺服器軟體是 Exim / Dovecot / cPanel。

您知道為什麼發送過程緩慢嗎?

謝謝!

如果沒有看到您的 Exim 配置,則無法確定,但是日誌的第一行:

30132 ident connection to 89.238.207.49 failed: Connection refused

表示您的問題是典型的ident查找延遲。Exim FAQ 中記錄了這一點:

進出口辨識電話

進出口 SMTP 延遲

以及Exim 文件的第 14 章。ident 查詢延遲的預設值為 5 秒,但在舊版本的 Exim 中為 30 秒。

檢查配置選項,如有必要,將其設置為零,這將禁用呼叫。

rfc1413_query_timeout = 0s

引用自:https://serverfault.com/questions/310854