
我正在嘗試在我的 OSX 10.5.6 機器上設定 fetchmail。我已按如下方式設定 .fetchmailrc:
poll my.mailserver.com with proto IMAP
timeout 30
user "username" is "username" here options ssl keep
我使用 .netrc 檔案來儲存我的使用者名稱/密碼,如下所示:
machine my.mailserver.com
login username
password secret
但是,當我運行 fetchmail 時,出現以下錯誤:
reading message [email protected]:1 of 458 (4436 octets)
fetchmail: timeout after 30 seconds waiting for listener to respond.
fetchmail: socket error while fetching from [email protected] and delivering to SMTP host localhost
fetchmail: Query status=2 (SOCKET)
fetchmail: Server certificate verification error: unable to get local issuer certificate
fetchmail: Server certificate verification error: certificate not trusted
fetchmail: Server certificate verification error: unable to verify the first certificate
fetchmail: Error exchanging credentials
看來 fetchmail 可以正常登錄,但它無法向 postfix 傳遞任何內容(我已經透過 telnet 到 localhost:25 驗證它已啟動並運行)。
接下來,我使用 -vv 標誌呼叫 fetchmail 以獲取有關正在發生的情況的一些額外資訊。我注意到以下奇怪的訊息:
Trying to connect to 208.97.132.126/25...fetchmail: timeout after 5 seconds waiting for listener to respond.
fetchmail: 6.3.8 querying my.mailserver.com (protocol POP3) at Tue, 14 Jul 2009 18:20:09 +1000 (EST): poll completed
fetchmail: discarding new UID list
fetchmail: Query status=2 (SOCKET)
這個IP位址很奇怪。 fetchmail 不應該只嘗試連接到本機主機以進行訊息傳遞嗎?快速 nslookup 顯示目標主機網域是 jankymail-mx1.g.dreamhost.com。哇?
順便說一句,這一切都是透過開箱即用的 fetchmail 安裝完成的——這是一台全新的 iMac!有誰知道會發生什麼事或是我做錯了什麼?
答案1
新增選項:smtphost localhost
或甚至smtphost 127.0.0.1
告訴它傳遞到本機。我不知道為什麼它預設為其他東西(這是你的整個 fetchmail 配置嗎?)。
實際上,這可能是它試圖使用 ETRN 之類的;該 IP 解析為 jankymail-mx1.g.dreamhost.com...這是您的郵件伺服器嗎?
此外,如果憑證是自簽署的或與主機名稱不匹配,您可能需要sslcommonname
或選項。sslfingerprint