未find主机名或域

我在centOS 5.4上安装了amavis + postfix + spamassassin。 “/ etc / hosts”文件包含:

127.0.0.1 localhost.localdomain localhost ::1 localhost6.localdomain6 localhost6 67.215.65.132 mail.sufalamtech.local mail 

当我发送邮件时,发生以下错误:

 Apr 8 06:20:53 mail sendmail[3229]: o380oqu7003229: from=root, size=62, class=0, nrcpts=1, msgid=<[email protected]>, relay=root@localhost Apr 8 06:20:53 mail postfix/smtpd[3230]: connect from mail.sufalamtech.local[127.0.0.1] Apr 8 06:20:53 mail sendmail[3229]: STARTTLS=client, relay=[127.0.0.1], version=TLSv1/SSLv3, verify=FAIL, cipher=DHE-RSA-AES256-SHA, bits=256/256 Apr 8 06:20:54 mail postfix/smtpd[3230]: 5A53C1A5989: client=mail.sufalamtech.local[127.0.0.1], [email protected] Apr 8 06:20:54 mail postfix/cleanup[3238]: 5A53C1A5989: message-id=<[email protected]> Apr 8 06:20:54 mail sendmail[3229]: o380oqu7003229: [email protected], ctladdr=root (0/0), delay=00:00:02, xdelay=00:00:01, mailer=relay, pri=30062, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (Ok: queued as 5A53C1A5989) Apr 8 06:20:54 mail postfix/qmgr[3107]: 5A53C1A5989: from=<[email protected]>, size=587, nrcpt=1 (queue active) Apr 8 06:20:54 mail postfix/smtpd[3230]: disconnect from mail.sufalamtech.local[127.0.0.1] Apr 8 06:20:54 mail postfix/smtp[3240]: 5A53C1A5989: to=<[email protected]>, relay=none, delay=0.63, delays=0.17/0.1/0.36/0, dsn=5.4.4, status=bounced (Host or domain name not found. Name service error for name=mail.sufalamtech.local type=A: Host not found) Apr 8 06:20:54 mail postfix/cleanup[3238]: E73C51A5987: message-id=<[email protected]> Apr 8 06:20:54 mail postfix/qmgr[3107]: E73C51A5987: from=<>, size=2594, nrcpt=1 (queue active) Apr 8 06:20:54 mail postfix/bounce[3241]: 5A53C1A5989: sender non-delivery notification: E73C51A5987 Apr 8 06:20:54 mail postfix/qmgr[3107]: 5A53C1A5989: removed Apr 8 06:20:55 mail postfix/local[3242]: E73C51A5987: to=<[email protected]>, relay=local, delay=0.15, delays=0.02/0.1/0/0.03, dsn=2.0.0, status=sent (delivered to mailbox) Apr 8 06:20:55 mail postfix/local[3242]: warning: host not found: localhost Apr 8 06:20:55 mail postfix/qmgr[3107]: E73C51A5987: removed Apr 8 06:21:04 mail postfix/qmgr[3107]: warning: connect to transport amavis: No such file or directory Apr 8 06:22:04 mail postfix/qmgr[3107]: warning: connect to transport amavis: No such file or directory 

你有没有尝试任何诊断?

如果从命令行查询,会发生什么情况:

 host mail.sufalamtech.local 

如果回来的主机没有find,那么你有一个问题以外的后缀。 例如,/etc/nsswitch.conf可能只列出dns作为主机的parsing器。如果您希望它使用主机文件,那么“files”必须出现在nsswitch.conf中的“hosts”旁边。

如果你的host命令没有问题,那么它可能是postfixconfiguration中的一些东西,它触发了名称服务查找。 你在使用传输文件吗?

在postfix邮件列表中,他们总是要求用户发送postconf -n的输出,这会显示configuration中默认设置的所有更改。