传递暂时中止:未find主机或域名

我有两个独立的域ad.vz和ad2.vz,它们之间有网关。 有3个后缀服务器:

  • mailad.ad.vz – 第一个域中的postfix服务器
  • mailsh – 带有后缀和两个networking适配器的网关
  • mailinet.ad2.vz – 第二个域中的postfix服务器

邮件只能连接一个networking区域。 有工作中继,每30秒打开/closureseth。 我开始在mailad发送20个字母,每30秒500KB的压力testing。 有时队列开始积累。 我可以在maillog中看到如下消息:

Sep 4 08:51:01 mailsh postfix/error[9602]: CFA5E131A7: to=<[email protected]>, relay=none, delay=33, delays=32/0/0/0, dsn=4.4.3, status=deferred (delivery temporarily suspended: Host or domain name not found. Name service error for name=mailinet.ad.vz type=MX: Host not found, try again)" 

每当适配器启动时,我发送命令postqueue -f

为什么队列可以积累?

mailad postconf:

 alias_database = hash:/etc/aliases alias_maps = hash:/etc/aliases command_directory = /usr/sbin config_directory = /etc/postfix daemon_directory = /usr/libexec/postfix data_directory = /var/lib/postfix debug_peer_level = 2 html_directory = no inet_interfaces = all inet_protocols = all mail_owner = postfix mailq_path = /usr/bin/mailq.postfix manpage_directory = /usr/share/man mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain mydomain = vzavod.ru myhostname = mailad.vzavod.ru newaliases_path = /usr/bin/newaliases.postfix queue_directory = /var/spool/postfix readme_directory = /usr/share/doc/postfix-2.6.6/README_FILES sample_directory = /usr/share/doc/postfix-2.6.6/samples sendmail_path = /usr/sbin/sendmail.postfix setgid_group = postdrop transport_maps = hash:/etc/postfix/transport unknown_local_recipient_reject_code = 550 transport settings: vzavod.ru local * smtp:mailsh.ad.vz 

mailsh postconf:

 alias_database = hash:/etc/aliases alias_maps = hash:/etc/aliases command_directory = /usr/sbin config_directory = /etc/postfix daemon_directory = /usr/libexec/postfix data_directory = /var/lib/postfix debug_peer_level = 2 html_directory = no inet_interfaces = all inet_protocols = all mail_owner = postfix mailq_path = /usr/bin/mailq.postfix manpage_directory = /usr/share/man mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain mydomain = vzavod.ru myhostname = mailsh.vzavod.ru newaliases_path = /usr/bin/newaliases.postfix queue_directory = /var/spool/postfix readme_directory = /usr/share/doc/postfix-2.6.6/README_FILES sample_directory = /usr/share/doc/postfix-2.6.6/samples sendmail_path = /usr/sbin/sendmail.postfix setgid_group = postdrop transport_maps = hash:/etc/postfix/transport unknown_local_recipient_reject_code = 550 

运输设置:

 * smtp:mailinet.ad.vz vzavod.ru smtp:mailad.ad.vz 

看起来你的情况看起来类似于本文中的情景: 在拨号机器中的后缀 。

从那篇文章中拿出来,这里有一些考虑。

  • 禁用自发SMTP邮件传递(如果只使用按需拨号IP)。

    使用下面的参数,除非手动运行postqueue -f否则postfix将不会尝试发送电子邮件。 将此参数放在main.cf 。 更多信息在这里 。

     defer_transports = smtp # (Only for on-demand dialup IP hosts) 
  • 禁用SMTP客户端DNS查找(仅拨号局域网)。

    在Postfix SMTP和LMTP客户端中禁用DNS查找。 禁用时,主机将使用getaddrinfo()系统库例程查找,该例程通常也在/ etc / hosts中查找。 因此,将mailad.ad.vz放在/etc/hosts 。 例如

     # echo "192.168.1.99 mailad.ad.vz" >> /etc/hosts 

    并在main.cf添加此参数

     disable_dns_lookups = yes #(Only for on-demand dialup IP hosts)