1 (edited by hackerzyh 2018-06-20 09:24:46)

Topic: 接收send.vip.com邮件异常----已解决

==== Required information ====
- iRedMail version (check /etc/iredmail-release):
- Linux/BSD distribution name and version:
- Store mail accounts in which backend (LDAP/MySQL/PGSQL):
- Web server (Apache or Nginx):
- Manage mail accounts with iRedAdmin-Pro?
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
======== Required information ====
- iRedMail version (check /etc/iredmail-release):
- Linux/BSD distribution name and version: debian8
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): mysql
- Web server (Apache or Nginx):apache
- Manage mail accounts with iRedAdmin-Pro? iredmail 0.9.7 without Pro
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
====
接收@send.vip.com的邮件异常,在greylisting 关闭情况下,postfix 的debug日志如下 ,当出现日志的情况下,无法收到@send.vip.com邮件,或延迟很久(30分钟左右)才可以收到
Oct 30 10:46:37 mail postfix/postscreen[19263]: PASS OLD [61.160.43.31]:22671
Oct 30 10:46:37 mail postfix/smtpd[27939]: connect from mta31.send.vip.com[61.160.43.31]
Oct 30 10:46:37 mail postfix/smtpd[27939]: smtp_stream_setup: maxtime=300 enable_deadline=0
Oct 30 10:46:37 mail postfix/smtpd[27939]: match_hostname: mta31.send.vip.com ~? 127.0.0.1
Oct 30 10:46:37 mail postfix/smtpd[27939]: match_hostaddr: 61.160.43.31 ~? 127.0.0.1
Oct 30 10:46:37 mail postfix/smtpd[27939]: match_list_match: mta31.send.vip.com: no match
Oct 30 10:46:37 mail postfix/smtpd[27939]: match_list_match: 61.160.43.31: no match
Oct 30 10:46:37 mail postfix/smtpd[27939]: send attr request = connect
Oct 30 10:46:37 mail postfix/smtpd[27939]: send attr ident = smtpd:61.160.43.31
Oct 30 10:46:37 mail postfix/smtpd[27939]: private/anvil: wanted attribute: status
Oct 30 10:46:37 mail postfix/smtpd[27939]: input attribute name: status
Oct 30 10:46:37 mail postfix/smtpd[27939]: input attribute value: 0
Oct 30 10:46:37 mail postfix/smtpd[27939]: private/anvil: wanted attribute: count
Oct 30 10:46:37 mail postfix/smtpd[27939]: input attribute name: count
Oct 30 10:46:37 mail postfix/smtpd[27939]: input attribute value: 1
Oct 30 10:46:37 mail postfix/smtpd[27939]: private/anvil: wanted attribute: rate
Oct 30 10:46:37 mail postfix/smtpd[27939]: input attribute name: rate
Oct 30 10:46:37 mail postfix/smtpd[27939]: input attribute value: 1
Oct 30 10:46:37 mail postfix/smtpd[27939]: private/anvil: wanted attribute: (list terminator)
Oct 30 10:46:37 mail postfix/smtpd[27939]: input attribute name: (end)
Oct 30 10:46:37 mail postfix/smtpd[27939]: > mta31.send.vip.com[61.160.43.31]: 220 mail.mailmehow.com
Oct 30 10:46:37 mail postfix/smtpd[27939]: xsasl_dovecot_server_create: SASL service=smtp, realm=(null)
Oct 30 10:46:37 mail postfix/smtpd[27939]: name_mask: noanonymous
Oct 30 10:46:37 mail postfix/smtpd[27939]: xsasl_dovecot_server_mech_filter: keep mechanism: PLAIN
Oct 30 10:46:37 mail postfix/smtpd[27939]: xsasl_dovecot_server_mech_filter: keep mechanism: LOGIN
Oct 30 10:46:37 mail postfix/smtpd[27939]: watchdog_pat: 0x55f6ee07a630
Oct 30 10:46:37 mail postfix/smtpd[27939]: smtp_get: EOF
Oct 30 10:46:37 mail postfix/smtpd[27939]: match_hostname: mta31.send.vip.com ~? 127.0.0.1
Oct 30 10:46:37 mail postfix/smtpd[27939]: match_hostaddr: 61.160.43.31 ~? 127.0.0.1
Oct 30 10:46:37 mail postfix/smtpd[27939]: match_list_match: mta31.send.vip.com: no match
Oct 30 10:46:37 mail postfix/smtpd[27939]: match_list_match: 61.160.43.31: no match
Oct 30 10:46:37 mail postfix/smtpd[27939]: send attr request = disconnect
Oct 30 10:46:37 mail postfix/smtpd[27939]: send attr ident = smtpd:61.160.43.31
Oct 30 10:46:37 mail postfix/smtpd[27939]: private/anvil: wanted attribute: status
Oct 30 10:46:37 mail postfix/smtpd[27939]: input attribute name: status
Oct 30 10:46:37 mail postfix/smtpd[27939]: input attribute value: 0
Oct 30 10:46:37 mail postfix/smtpd[27939]: private/anvil: wanted attribute: (list terminator)
Oct 30 10:46:37 mail postfix/smtpd[27939]: input attribute name: (end)
Oct 30 10:46:37 mail postfix/smtpd[27939]: lost connection after CONNECT from mta31.send.vip.com[61.160.43.31]
Oct 30 10:46:37 mail postfix/smtpd[27939]: disconnect from mta31.send.vip.com[61.160.43.31]

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2 (edited by hackerzyh 2018-06-20 09:25:26)

Re: 接收send.vip.com邮件异常----已解决

postfix配置信息
alias_database = hash:/etc/postfix/aliases
alias_maps = hash:/etc/postfix/aliases
allow_min_user = no
allow_percent_hack = no
biff = no
body_checks = pcre:/etc/postfix/body_checks.pcre
command_directory = /usr/sbin
config_directory = /etc/postfix
content_filter = smtp-amavis:[127.0.0.1]:10024
daemon_directory = /usr/lib/postfix
data_directory = /var/lib/postfix
debug_peer_level = 2
debug_peer_list = send.vip.com
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
dovecot_destination_recipient_limit = 1
enable_original_recipient = no
header_checks = pcre:/etc/postfix/header_checks
inet_interfaces = all
inet_protocols = all
lmtp_tls_mandatory_protocols = !SSLv2 !SSLv3
lmtp_tls_protocols = !SSLv2 !SSLv3
mail_owner = postfix
mailbox_size_limit = 59768832
mailq_path = /usr/bin/mailq
maximal_queue_lifetime = 3
message_size_limit = 57671680
mydestination = $myhostname, localhost, localhost.localdomain
virtual_alias_domains =
virtual_alias_maps = proxy:mysql:/etc/postfix/mysql/virtual_alias_maps.cf proxy:mysql:/etc/postfix/mysql/domain_alias_maps.cf proxy:mysql:/etc/postfix/mysql/catchall_maps.cf proxy:mysql:/etc/postfix/mysql/domain_alias_catchall_maps.cf
virtual_gid_maps = static:2000
virtual_mailbox_base = /var/vmail
virtual_mailbox_domains = proxy:mysql:/etc/postfix/mysql/virtual_mailbox_domains.cf
virtual_mailbox_maps = proxy:mysql:/etc/postfix/mysql/virtual_mailbox_maps.cf
virtual_minimum_uid = 2000
virtual_transport = dovecot
virtual_uid_maps = static:2000

3

Re: 接收send.vip.com邮件异常----已解决

从 log 看不出 postfix 配置有什么问题。退信是否有什么错误信息?

另外,postfix 配置请贴 "postconf -n" 的输出,你贴的这么长一串,实在看花眼。

4

Re: 接收send.vip.com邮件异常----已解决

postfix 配置信息已经在二楼重新编辑

关于是否真的会退信,我经过前几天的观察,我个人判断应该是没有退信。因为我每次发送验证码邮件时候,如果log里面显示如下信息(未开启debug的日志信息)
Oct 26 10:38:38 mail postfix/postscreen[32194]: PASS OLD [61.160.43.35]:16176
Oct 26 10:38:38 mail postfix/smtpd[1091]: connect from mta35.send.vip.com[61.160.43.35]
Oct 26 10:38:39 mail postfix/smtpd[1091]: 0E5F0E06B5: client=mta35.send.vip.com[61.160.43.35]
Oct 26 10:38:39 mail postfix/smtpd[1091]: lost connection after RCPT from mta35.send.vip.com[61.160.43.35]
Oct 26 10:38:39 mail postfix/smtpd[1091]: disconnect from mta35.send.vip.com[61.160.43.35]

都要延迟很久才可以收到。对方是唯品会,尝试联系对方邮件管理员无果

5

Re: 接收send.vip.com邮件异常----已解决

可以尝试将 mtaXX.send.vip.com 加入白名单。
FYI: http://www.iredmail.org/docs/manage.iredapd.html

6 (edited by hackerzyh 2017-11-02 11:05:25)

Re: 接收send.vip.com邮件异常----已解决

ZhangHuangbin wrote:

可以尝试将 mtaXX.send.vip.com 加入白名单。
FYI: http://www.iredmail.org/docs/manage.iredapd.html


昨天把mtaxx.send.vip.com 对应的ip全加入了。重启iredapd,观察一下,还是一样效果
今天早上发送了一次验证码邮件,观察日志如下:
大概隔9-10分钟会重新连接一下我这边服务器,然后就断开了
root@mail:/opt/iredapd/tools# tail -f  /var/log/mail.log  | grep "send.vip.com"
Nov  2 10:06:10 mail postfix/smtpd[4797]: connect from mta35.send.vip.com[61.160.43.35]
Nov  2 10:06:10 mail postfix/smtpd[4797]: match_hostname: mta35.send.vip.com ~? 127.0.0.1
Nov  2 10:06:10 mail postfix/smtpd[4797]: match_list_match: mta35.send.vip.com: no match
Nov  2 10:06:10 mail postfix/smtpd[4797]: > mta35.send.vip.com[61.160.43.35]: 220 mail.mailmehow.com
Nov  2 10:06:10 mail postfix/smtpd[4797]: match_hostname: mta35.send.vip.com ~? 127.0.0.1
Nov  2 10:06:10 mail postfix/smtpd[4797]: match_list_match: mta35.send.vip.com: no match
Nov  2 10:06:10 mail postfix/smtpd[4797]: lost connection after CONNECT from mta35.send.vip.com[61.160.43.35]
Nov  2 10:06:10 mail postfix/smtpd[4797]: disconnect from mta35.send.vip.com[61.160.43.35]
Nov  2 10:15:10 mail postfix/smtpd[4797]: connect from mta32.send.vip.com[61.160.43.32]
Nov  2 10:15:10 mail postfix/smtpd[4797]: match_hostname: mta32.send.vip.com ~? 127.0.0.1
Nov  2 10:15:10 mail postfix/smtpd[4797]: match_list_match: mta32.send.vip.com: no match
Nov  2 10:15:10 mail postfix/smtpd[4797]: > mta32.send.vip.com[61.160.43.32]: 220 mail.mailmehow.com
Nov  2 10:15:10 mail postfix/smtpd[4797]: match_hostname: mta32.send.vip.com ~? 127.0.0.1
Nov  2 10:15:10 mail postfix/smtpd[4797]: match_list_match: mta32.send.vip.com: no match
Nov  2 10:15:10 mail postfix/smtpd[4797]: lost connection after CONNECT from mta32.send.vip.com[61.160.43.32]
Nov  2 10:15:10 mail postfix/smtpd[4797]: disconnect from mta32.send.vip.com[61.160.43.32]
Nov  2 10:26:09 mail postfix/smtpd[14407]: connect from mta39.send.vip.com[61.160.43.39]
Nov  2 10:26:09 mail postfix/smtpd[14407]: match_hostname: mta39.send.vip.com ~? 127.0.0.1
Nov  2 10:26:09 mail postfix/smtpd[14407]: match_list_match: mta39.send.vip.com: no match
Nov  2 10:26:09 mail postfix/smtpd[14407]: > mta39.send.vip.com[61.160.43.39]: 220 mail.mailmehow.com
Nov  2 10:26:09 mail postfix/smtpd[14407]: match_hostname: mta39.send.vip.com ~? 127.0.0.1
Nov  2 10:26:09 mail postfix/smtpd[14407]: match_list_match: mta39.send.vip.com: no match
Nov  2 10:26:09 mail postfix/smtpd[14407]: lost connection after CONNECT from mta39.send.vip.com[61.160.43.39]
Nov  2 10:26:09 mail postfix/smtpd[14407]: disconnect from mta39.send.vip.com[61.160.43.39]
Nov  2 10:46:32 mail postfix/smtpd[23236]: connect from mta31.send.vip.com[61.160.43.31]
Nov  2 10:46:32 mail postfix/smtpd[23236]: match_hostname: mta31.send.vip.com ~? 127.0.0.1
Nov  2 10:46:32 mail postfix/smtpd[23236]: match_list_match: mta31.send.vip.com: no match
Nov  2 10:46:32 mail postfix/smtpd[23236]: > mta31.send.vip.com[61.160.43.31]: 220 mail.mailmehow.com
Nov  2 10:46:32 mail postfix/smtpd[23236]: match_hostname: mta31.send.vip.com ~? 127.0.0.1
Nov  2 10:46:32 mail postfix/smtpd[23236]: match_list_match: mta31.send.vip.com: no match
Nov  2 10:46:32 mail postfix/smtpd[23236]: lost connection after CONNECT from mta31.send.vip.com[61.160.43.31]
Nov  2 10:46:32 mail postfix/smtpd[23236]: disconnect from mta31.send.vip.com[61.160.43.31]
Nov  2 10:57:30 mail postfix/smtpd[9510]: connect from mta34.send.vip.com[61.160.43.34]
Nov  2 10:57:30 mail postfix/smtpd[9510]: match_hostname: mta34.send.vip.com ~? 127.0.0.1
Nov  2 10:57:30 mail postfix/smtpd[9510]: match_list_match: mta34.send.vip.com: no match
Nov  2 10:57:30 mail postfix/smtpd[9510]: > mta34.send.vip.com[61.160.43.34]: 220 mail.mailmehow.com
Nov  2 10:57:30 mail postfix/smtpd[9510]: match_hostname: mta34.send.vip.com ~? 127.0.0.1
Nov  2 10:57:30 mail postfix/smtpd[9510]: match_list_match: mta34.send.vip.com: no match
Nov  2 10:57:30 mail postfix/smtpd[9510]: lost connection after CONNECT from mta34.send.vip.com[61.160.43.34]
Nov  2 10:57:30 mail postfix/smtpd[9510]: disconnect from mta34.send.vip.com[61.160.43.34]

7

Re: 接收send.vip.com邮件异常----已解决

请作者帮忙回复一下

8

Re: 接收send.vip.com邮件异常----已解决

hackerzyh wrote:

Nov  2 11:20:48 mail postfix/smtpd[29654]: 127.0.0.1:7777: wanted attribute: action
Nov  2 11:20:48 mail postfix/smtpd[29654]: input attribute name: action
Nov  2 11:20:48 mail postfix/smtpd[29654]: input attribute value: OK wblist=(579, 72, 'W')
Nov  2 11:20:48 mail postfix/smtpd[29654]: 127.0.0.1:7777: wanted attribute: (list terminator)
Nov  2 11:20:48 mail postfix/smtpd[29654]: input attribute name: (end)
Nov  2 11:20:48 mail postfix/smtpd[29654]: check_table_result: inet:127.0.0.1:7777 OK wblist=(579, 72, 'W') policy query
Nov  2 11:20:48 mail postfix/smtpd[29654]: match_list_match: OK: no match

从这里看,白名单已经生效了。

hackerzyh wrote:

Nov  2 11:20:48 mail postfix/smtpd[29654]: input attribute name: queue_id
Nov  2 11:20:48 mail postfix/smtpd[29654]: input attribute value: 84075E0A1D
Nov  2 11:20:48 mail postfix/smtpd[29654]: public/cleanup socket: wanted attribute: (list terminator)
Nov  2 11:20:48 mail postfix/smtpd[29654]: input attribute name: (end)
...
Nov  2 11:20:48 mail postfix/smtpd[29654]: 84075E0A1D: client=mta36.send.vip.com[61.160.43.36]

这里表示 postfix 已经生成了 queue id,应该已经放入队列了。

9 (edited by hackerzyh 2018-06-20 09:29:47)

Re: 接收send.vip.com邮件异常----已解决

ZhangHuangbin wrote:
hackerzyh wrote:

Nov  2 11:20:48 mail postfix/smtpd[29654]: 127.0.0.1:7777: wanted attribute: action
Nov  2 11:20:48 mail postfix/smtpd[29654]: input attribute name: action
Nov  2 11:20:48 mail postfix/smtpd[29654]: input attribute value: OK wblist=(579, 72, 'W')
Nov  2 11:20:48 mail postfix/smtpd[29654]: 127.0.0.1:7777: wanted attribute: (list terminator)
Nov  2 11:20:48 mail postfix/smtpd[29654]: input attribute name: (end)
Nov  2 11:20:48 mail postfix/smtpd[29654]: check_table_result: inet:127.0.0.1:7777 OK wblist=(579, 72, 'W') policy query
Nov  2 11:20:48 mail postfix/smtpd[29654]: match_list_match: OK: no match

从这里看,白名单已经生效了。

hackerzyh wrote:

Nov  2 11:20:48 mail postfix/smtpd[29654]: input attribute name: queue_id
Nov  2 11:20:48 mail postfix/smtpd[29654]: input attribute value: 84075E0A1D
Nov  2 11:20:48 mail postfix/smtpd[29654]: public/cleanup socket: wanted attribute: (list terminator)
Nov  2 11:20:48 mail postfix/smtpd[29654]: input attribute name: (end)
...
Nov  2 11:20:48 mail postfix/smtpd[29654]: 84075E0A1D: client=mta36.send.vip.com[61.160.43.36]

这里表示 postfix 已经生成了 queue id,应该已经放入队列了。

感谢作者!
我来分享一下我这个问题解决的方法:
公司的防火墙(SONICWALL NSA 3600 )里面的一个配置(RBL Filter) 频繁中断双方服务器回话,造成对方服务器延迟发送邮件,把这个功能禁用后可以正常收取邮件。
另外我的服务器也无法正常收取google的邮件,也是由于防火墙的这个配置造成的,在解决问题的过程中发现不少国内外用户也有类似这样的问题,不知是不是同样的原因