Sendmail的域名和子域名问题


以前就没搞过sendmail,开始配过qmail,后来一直用Postfix。

今天www服务器那边用sendmail发不出邮件去了,而发到其他的邮箱没问题,

因为主机是www.xxx.com 而邮件服务器又在别的上面。mail.xxx.com

所以sendmail一发到xxx.com就报错。

Jan 16 10:34:18 web sendmail[19020]: n0G2YIwd019018: SYSERR(root): mail.xxx.co
m. config error: mail loops back to me (MX problem?)
Jan 16 10:34:18 web sendmail[19020]: n0G2YIwd019018: to=<help@xxx.com>, ctladd
r=<daemon@www.xxx.com> (2/2), delay=00:00:00, xdelay=00:00:00, mailer=esmtp, p
ri=121387, relay=mail.xxx.com. [222.173.95.50], dsn=5.3.5, stat=Local configur
ation error
Jan 16 10:34:18 web sendmail[19020]: n0G2YIwd019018: n0G2YIwd019020: DSN: Local
configuration error

到官方FAQ,看也不是它说的那种问题。自己添加一个DNS服务器问题依旧。

试着改一下sendmail的配置文件看看,  /etc/mail/sendmail.cf
改后正常。

# my official domain name
# … define this only if sendmail cannot automatically determine your domain
Dj$w.xxx.cn

估计你也能看明白了吧,就是不让sendmail自动获取域名,你自己指定一个。防止和xxx.com冲突。

  1. No comments yet.
(will not be published)