在我的 Postfix 服务器中不断收到“ NOQUEUE: 拒绝: 来自 mail-aa-bb-cc.google.com[11.22.33.44] 的 RCPT: 450 4.1.1 ...”

在我的 Postfix 服务器中不断收到“ NOQUEUE: 拒绝: 来自 mail-aa-bb-cc.google.com[11.22.33.44] 的 RCPT: 450 4.1.1 ...”

当我向 Postfix/Dovecot/Postgresql VPS 服务器发送电子邮件时,我一直遇到此异常:

  localhost postfix/smtpd[495]: connect from mail-aa-bb-cc.google.com[11.22.33.44]
  localhost postfix/smtpd[495]: NOQUEUE: reject: RCPT from mail-aa-bb-cc.google.com[11.22.33.44]: 450 4.1.1 <[email protected]>: Recipient address rejected: unverified address: host mail.my_postfix_domain.com[private/dovecot-lmtp] said: 451 4.3.0 <[email protected]> Temporary internal error (in reply to RCPT TO command); from=<[email protected]> to=<[email protected]> proto=ESMTP helo=<mail-aa-bb-cc.google.com>
  localhost postfix/smtpd[495]: disconnect from mail-aa-bb-cc.google.com[11.22.33.44] ehlo=2 starttls=1 mail=1 rcpt=0/1 data=0/1 quit=1 commands=5/7
  localhost postfix/smtpd[521]: connect from mail-wm0-f50.google.com[33.44.55.66]
  localhost postfix/smtpd[521]: NOQUEUE: reject: RCPT from mail-wm0-f50.google.com[33.44.55.66]: 450 4.1.1 <[email protected]>: Recipient address rejected: unverified address: host mail.my_postfix_domain.com[private/dovecot-lmtp] said: 451 4.3.0 <[email protected]> Temporary internal error (in reply to RCPT TO command); from=<[email protected]> to=<[email protected]> proto=ESMTP helo=<mail-wm0-f50.google.com>

可能的原因是什么?我应该包含哪些配置数据?

1)

$ sudo postconf -n
alias_database =
alias_maps =
allow_percent_hack = no
biff = no
command_directory = /usr/bin
compatibility_level = 2
daemon_directory = /usr/lib/postfix/bin
data_directory = /var/lib/postfix
debug_peer_level = 2
debugger_command = PATH=/bin:/usr/bin:/usr/local/bin:/usr/X11R6/bin ddd $daemon_directory/$process_name $process_id & sleep 5
disable_vrfy_command = yes
home_mailbox = Maildir/
html_directory = no
inet_interfaces = all
inet_protocols = ipv4
mail_owner = postfix
mail_spool_directory = /var/mail/local
mailbox_size_limit = 0
mailq_path = /usr/bin/mailq
manpage_directory = /usr/share/man
message_size_limit = 51200000
meta_directory = /etc/postfix
mydestination = $mydomain, localhost.$mydomain, localhost
mydomain = my_domain123.com
myhostname = mail.my_domain123.com
mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
myorigin = $mydomain
newaliases_path = /usr/bin/newaliases
queue_directory = /var/spool/postfix
readme_directory = /usr/share/doc/postfix
recipient_delimiter = +
sample_directory = /etc/postfix
sendmail_path = /usr/bin/sendmail
setgid_group = postdrop
shlib_directory = /usr/lib/postfix
show_user_unknown_table_name = no
smtp_dns_support_level = dnssec
smtp_tls_security_level = dane
smtp_tls_session_cache_database = btree:${data_directory}/smtp_tlscache
smtpd_client_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unknown_reverse_client_hostname, reject_unauth_pipelining
smtpd_data_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_multi_recipient_bounce, reject_unauth_pipelining
smtpd_helo_required = yes
smtpd_helo_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_invalid_helo_hostname, reject_unauth_pipelining
smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_non_fqdn_recipient, reject_unknown_recipient_domain, reject_unauth_pipelining
smtpd_relay_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_non_fqdn_recipient, reject_unknown_recipient_domain, reject_unauth_destination
smtpd_sasl_auth_enable = yes
smtpd_sasl_path = private/auth
smtpd_sasl_security_options = noanonymous, noplaintext
smtpd_sasl_tls_security_options = noanonymous
smtpd_sasl_type = dovecot
smtpd_sender_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_non_fqdn_sender, reject_unknown_sender_domain, reject_unauth_pipelining
smtpd_tls_auth_only = yes
smtpd_tls_cert_file = /etc/letsencrypt/live/mail.my_domain123.com/fullchain.pem
smtpd_tls_dh1024_param_file = /etc/ssl/dh2048.pem
smtpd_tls_dh512_param_file = /etc/ssl/dh512.pem
smtpd_tls_key_file = /etc/letsencrypt/live/mail.my_domain123.com/privkey.pem
smtpd_tls_mandatory_ciphers = high
smtpd_tls_mandatory_protocols = !SSLv2, !SSLv3, !TLSv1, !TLSv1.1, TLSv1.2
smtpd_tls_received_header = yes
smtpd_tls_security_level = may
smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_tlscache
strict_rfc821_envelopes = yes
swap_bangpath = no
tls_high_cipherlist = ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA256
tls_ssl_options = no_ticket, no_compression
unknown_local_recipient_reject_code = 550
virtual_alias_domains =
virtual_mailbox_domains = pgsql:/etc/postfix/virtual_mailbox_domains.cf
virtual_mailbox_maps = pgsql:/etc/postfix/virtual_mailbox_maps.cf
virtual_transport = lmtp:unix:private/dovecot-lmtp

和 2):

  $ sudo postconf -M
  smtp       inet  n       -       n       -       -       smtpd
  pickup     unix  n       -       n       60      1       pickup
  cleanup    unix  n       -       n       -       0       cleanup
  qmgr       unix  n       -       n       300     1       qmgr
  tlsmgr     unix  -       -       n       1000?   1       tlsmgr
  rewrite    unix  -       -       n       -       -       trivial-rewrite
  bounce     unix  -       -       n       -       0       bounce
  defer      unix  -       -       n       -       0       bounce
  trace      unix  -       -       n       -       0       bounce
  verify     unix  -       -       n       -       1       verify
  flush      unix  n       -       n       1000?   0       flush
  proxymap   unix  -       -       n       -       -       proxymap
  proxywrite unix  -       -       n       -       1       proxymap
  smtp       unix  -       -       n       -       -       smtp
  relay      unix  -       -       n       -       -       smtp -o syslog_name=postfix/$service_name
  showq      unix  n       -       n       -       -       showq
  error      unix  -       -       n       -       -       error
  retry      unix  -       -       n       -       -       error
  discard    unix  -       -       n       -       -       discard
  local      unix  -       n       n       -       -       local
  virtual    unix  -       n       n       -       -       virtual
  lmtp       unix  -       -       n       -       -       lmtp
  anvil      unix  -       -       n       -       1       anvil
  scache     unix  -       -       n       -       1       scache
  smtp       inet  n       -       n       -       -       smtpd -o smtpd_sasl_auth_enable=no
  submission inet  n       -       y       -       -       smtpd -o syslog_name=postfix/submission -o smtpd_tls_security_level=encrypt -o smtpd_sasl_auth_enable=yes -o smtpd_sasl_type=dovecot -o smtpd_sasl_path=private/auth -o smtpd_sasl_security_options=noanonymous -o milter_macro_daemon_name=ORIGINATING -o smtpd_helo_required=no -o smtpd_helo_restrictions= -o cleanup_service_name=submission-header-cleanup

就接收邮件而言 - 没有问题。发送 - 我还没有尝试过。

答案1

似乎您没有设置收件人访问表。您需要确保邮件有路由。以下是我在云端的 smtp 中继上的收件人访问限制

smtpd_recipient_restrictions = check_recipient_access hash:/etc/postfix/recipient_access, permit_mynetworks, permit_auth_destination, reject_unauth_destination

相关内容