我無法從我的郵件服務器發送電子郵件。我已經嘗試了我遇到的每種可能的解決方案。首先,我能夠發送電子郵件,但他們要的垃圾郵件,所以我決定安裝OpenDKIM,並添加了KEY到DNS記錄。希望它能解決問題,但NO。Gmail阻止來自我的郵件服務器(Postfix)的電子郵件CentOS 6
錯誤日誌:
Jun 22 07:06:13 cvps9320765968 postfix/pickup[23538]: 8C65841E71: uid=48 from=<apache>
Jun 22 07:06:13 cvps9320765968 postfix/trivial-rewrite[23612]: warning: database /etc/postfix/virtual.db is older than source file /etc/postfix/virtual
Jun 22 07:06:13 cvps9320765968 postfix/cleanup[23611]: 8C65841E71: message-id=<[email protected]>
Jun 22 07:06:13 cvps9320765968 opendkim[23603]: 8C65841E71: DKIM-Signature field added (s=mail, d=some.com)
Jun 22 07:06:13 cvps9320765968 postfix/qmgr[23539]: 8C65841E71: from=<[email protected]>, size=2050, nrcpt=1 (queue active)
Jun 22 07:06:13 cvps9320765968 postfix/smtp[23614]: 8C65841E71: host gmail-smtp-in.l.google.com[74.125.28.26] refused to talk to me: 421-4.7.0 [104.168.147.5] Our system has detected an unusual amount of 421-4.7.0 unsolicited mail originating from your IP address. To protect our 421-4.7.0 users from spam, mail sent from your IP address has been temporarily 421-4.7.0 blocked. Please visit 421-4.7.0 https://support.google.com/mail/answer/81126 to review our Bulk Email 421 4.7.0 Senders Guidelines. i76si32559854pfe.149 - gsmtp
Jun 22 07:06:13 cvps9320765968 postfix/smtp[23614]: 8C65841E71: host alt1.gmail-smtp-in.l.google.com[64.233.181.26] refused to talk to me: 421-4.7.0 [104.168.147.5] Our system has detected an unusual amount of 421-4.7.0 unsolicited mail originating from your IP address. To protect our 421-4.7.0 users from spam, mail sent from your IP address has been temporarily 421-4.7.0 blocked. Please visit 421-4.7.0 https://support.google.com/mail/answer/81126 to review our Bulk Email 421 4.7.0 Senders Guidelines. g26si47746149ioj.174 - gsmtp
Jun 22 07:06:13 cvps9320765968 postfix/smtp[23614]: 8C65841E71: host alt2.gmail-smtp-in.l.google.com[173.194.219.26] refused to talk to me: 421-4.7.0 [104.168.147.5] Our system has detected an unusual amount of 421-4.7.0 unsolicited mail originating from your IP address. To protect our 421-4.7.0 users from spam, mail sent from your IP address has been temporarily 421-4.7.0 blocked. Please visit 421-4.7.0 https://support.google.com/mail/answer/81126 to review our Bulk Email 421 4.7.0 Senders Guidelines. n82si17200633ywd.387 - gsmtp
Jun 22 07:06:14 cvps9320765968 postfix/smtp[23614]: 8C65841E71: host alt3.gmail-smtp-in.l.google.com[74.125.192.26] refused to talk to me: 421-4.7.0 [104.168.147.5] Our system has detected an unusual amount of 421-4.7.0 unsolicited mail originating from your IP address. To protect our 421-4.7.0 users from spam, mail sent from your IP address has been temporarily 421-4.7.0 blocked. Please visit 421-4.7.0 https://support.google.com/mail/answer/81126 to review our Bulk Email 421 4.7.0 Senders Guidelines. t36si58896045qtb.55 - gsmtp
Jun 22 07:06:14 cvps9320765968 postfix/smtp[23614]: 8C65841E71: to=<[email protected]>, relay=alt4.gmail-smtp-in.l.google.com[74.125.141.26]:25, delay=0.66, delays=0.09/0.01/0.57/0, dsn=4.7.0, status=deferred (host alt4.gmail-smtp-in.l.google.com[74.125.141.26] refused to talk to me: 421-4.7.0 [104.168.147.5] Our system has detected an unusual amount of 421-4.7.0 unsolicited mail originating from your IP address. To protect our 421-4.7.0 users from spam, mail sent from your IP address has been temporarily 421-4.7.0 blocked. Please visit 421-4.7.0 https://support.google.com/mail/answer/81126 to review our Bulk Email 421 4.7.0 Senders Guidelines. 110si23287632uag.46 - gsmtp)
這裏是(增加smtpd_sasl_path = private/auth
否則郵件被髮送,但是移動到垃圾郵件後錯誤)我/etc/postfix/main.cf
:
soft_bounce = no
queue_directory = /var/spool/postfix
command_directory = /usr/sbin
daemon_directory = /usr/libexec/postfix
mail_owner = postfix
# The default_privs parameter specifies the default rights used by
# the local delivery agent for delivery to external file or command.
# These rights are used in the absence of a recipient user context.
# DO NOT SPECIFY A PRIVILEGED USER OR THE POSTFIX OWNER.
#
#default_privs = nobody
myhostname = some.com
mydomain = some.com
mydestination = $myhostname, localhost
unknown_local_recipient_reject_code = 550
mynetworks_style = host
#mailbox_transport = lmtp:unix:/var/lib/imap/socket/lmtp
local_destination_recipient_limit = 300
local_destination_concurrency_limit = 5
recipient_delimiter=+
virtual_alias_maps = hash:/etc/postfix/virtual
header_checks = regexp:/etc/postfix/header_checks
mime_header_checks = pcre:/etc/postfix/body_checks
smtpd_banner = $myhostname
debug_peer_level = 2
debugger_command =
PATH=/bin:/usr/bin:/usr/bin:/usr/X11R6/bin
xxgdb $daemon_directory/$process_name $process_id & sleep 5
sendmail_path = /usr/sbin/sendmail.postfix
newaliases_path = /usr/bin/newaliases.postfix
mailq_path = /usr/bin/mailq.postfix
setgid_group = postdrop
html_directory = no
manpage_directory = /usr/share/man
sample_directory = /usr/share/doc/postfix-2.3.3/samples
readme_directory = /usr/share/doc/postfix-2.3.3/README_FILES
smtpd_sasl_auth_enable = yes
smtpd_sasl_application_name = smtpd
smtpd_relay_restrictions = permit_sasl_authenticated,
permit_mynetworks,
reject_unauth_destination,
reject_invalid_hostname,
reject_non_fqdn_hostname,
reject_non_fqdn_sender,
reject_non_fqdn_recipient,
reject_unknown_sender_domain,
reject_unknown_recipient_domain,
reject_unauth_pipelining,
reject_rbl_client zen.spamhaus.org,
reject_rbl_client bl.spamcop.net,
reject_rbl_client dnsbl.njabl.org,
reject_rbl_client dnsbl.sorbs.net,
permit
#smtpd_sasl_type = dovecot
broken_sasl_auth_clients = yes
#smtpd_sasl_path = private/auth
smtpd_sasl_security_options = noanonymous
smtpd_sasl_local_domain =
broken_sasl_auth_clients = yes
smtpd_helo_required = yes
milter_protocol = 2
milter_default_action = accept
smtpd_milters = inet:localhost:12301
non_smtpd_milters = inet:localhost:12301
錯誤'smtpd_sasl_path =私人/ auth'否則發送郵件已經發送,但移動到垃圾郵件 – ryspbsk
你的問題是一個很好的,但它更關係到系統管理不是編程。因此,它是Stack Overflow的[off-topic](http://stackoverflow.com/help/on-topic),並且更適合[ServerFault](http://serverfault.com/)。 –
O_O啊。你說得對,它與編程無關。這是我第一次訪問ServerFault社區,因爲您向我提供了鏈接。我會在那裏發佈。謝謝sooo Anthony Geoghega! – ryspbsk