Linode Email 無法寄送的解法

Linode 於 2019/12/5 以後開得新帳號(原因:CAN-SPAM Act),連到外部 SMTP Port 預設都被擋掉,以至於全部 Connection timed out。

新開機器可以直接 telnet 測試看看:

$ telnet gmail-smtp-in.l.google.com 25
Trying 2404:6800:4008:c03::1b…
Trying 74.125.203.26…
telnet: Unable to connect to remote host: Connection timed out

正常狀況

$ telnet gmail-smtp-in.l.google.com 25
Trying 74.125.203.26…
Connected to gmail-smtp-in.l.google.com.
Escape character is '^]'.
220 mx.google.com ESMTP k2si12268129pld.364 - gsmtp

於 Postfix 的 /var/log/mail.log 會看到下述訊息:

Apr 29 12:47:24 localhost postfix/smtp[18520]: connect to gmail-smtp-in.l.google.com[74.125.203.27]:25: Connection timed out
Apr 29 12:47:24 localhost postfix/smtp[18521]: connect to gmail-smtp-in.l.google.com[108.177.97.27]:25: Connection timed out
Apr 29 12:47:24 localhost postfix/smtp[18523]: connect to gmail-smtp-in.l.google.com[64.233.189.26]:25: Connection timed out
Apr 29 12:47:54 localhost postfix/smtp[18523]: connect to alt1.gmail-smtp-in.l.google.com[108.177.9.27]:25: Connection timed out
Apr 29 12:48:24 localhost postfix/smtp[18523]: connect to alt2.gmail-smtp-in.l.google.com[209.85.234.26]:25: Connection timed out
Apr 29 12:48:54 localhost postfix/smtp[18522]: connect to alt3.gmail-smtp-in.l.google.com[142.250.11.27]:25: Connection timed out Apr 29 12:49:24 localhost postfix/smtp[18520]: connect to alt4.gmail-smtp-in.l.google.com[142.250.12.27]:25: Connection timed out

想要開通 Email 的 SMTP Port 需要做些設定,然後在於後台開 Ticket 申請。

閱讀全文〈Linode Email 無法寄送的解法〉