2014-01-05 39 views
1

我試圖通過Gmail無法對小牛

啓用outbond繼電器後綴我下面的所有步驟from this site啓用通過Gmail站中繼的後綴。

但無法接收郵件。

,並得到位於文件中的下列味精在/var/mail

host gmail-smtp-in.l.google.com[74.125.129.27] said: 
550-5.7.1 [106.78.175.213] The IP you're using to send mail is not 
authorized to 550-5.7.1 send email directly to our servers. Please use the 
SMTP relay at your 550-5.7.1 service provider instead. Learn more at 550 
5.7.1 http://support.google.com/mail/bin/answer.py?answer=10336 
j5si48631733pbs.31 - gsmtp (in reply to end of DATA command) 

其實我整合BOT和希望收到的成功或失敗的郵件。但沒有收到任何郵件,所以我搜索了一下,發現我必須爲出站啓用後綴。

我也嘗試在終端上使用mailx <my gmail address>,但沒有收到任何電子郵件。

回答

0

我將嘗試闡述一些我在類似情況下所獲得的樂趣。我已經安裝了服務器3.0,但是在那裏生活的事情可能會讓人惱火以追查。

在我的情況下,後綴正在運行/ Library/Server/Mail/Config/postfix。但是它從發佈版本轉移到了發佈版本,這使得你的舊配置開始混亂了你的構建。

在你的postfix中,你應該有一個main.cf.

我增加了一節:

>sudo nano main.cf 
smtpd_recipient_restrictions = permit_sasl_authenticated permit_mynetworks 
reject_unauth_destination 
smtpd_use_pw_server = yes 
mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain 
smtpd_pw_server_security_options = cram-md5,digest-md5,gssapi,login,plain 
smtpd_sasl_auth_enable = yes 
smtp_sasl_password_maps = hash:/etc/postfix/saslpasswd 
relayhost = [smtp.gmail.com]:587 

CTL + O,輸入保存

它的重要,現在要注意的,我們應對這種/等/後綴/ saslpasswd

sudo nano /etc/postfix/saslpasswd 
[smtp.gmail.com]:587 [email protected]:YourPassword*9 

CTL + O,進入保存。

還有一些問題,我沒有發現明顯的問題。

sudo postmap /etc/postfix/saslpasswd 
sudo postfix reload 

希望有幫助。帶有漂亮的開/關按鈕的基本郵件/服務器似乎不適合你。我不時重置我的密碼。當我這樣做時,我必須記住這些路徑,然後確保我發出最後兩條命令或者saslpasswd.db不同步。

好運