使用 sendmail 的新 Linux CentOS 设置-配置错误导致垃圾邮件问题

使用 sendmail 的新 Linux CentOS 设置-配置错误导致垃圾邮件问题

我最近购买了一款云 VPS 服务 - CENTOS 7。

我已经配置了我的网站,一切正常,但是我注意到并不总是能收到电子邮件。

我相信这些电子邮件是使用 PHP 邮件功能发送的 - 默认使用 sendmail。

/var/log/maillog我可以看到以下内容:

Sep 10 21:59:01 mail sendmail[2615]: u8AKx0ZK002614: to=root, ctladdr=<[email protected]> (48/48), delay=00:00:01, xdelay=00:00:01, mailer=local, pri=41036, dsn=2.0.0, stat=Sent
Sep 10 22:03:16 mail sendmail[2656]: u8AL3G7U002656: from=apache, size=10690, class=0, nrcpts=1, msgid=<[email protected]>, relay=apache@localhost
Sep 10 22:03:16 mail sendmail[2657]: u8AL3G7h002657: from=<[email protected]>, size=10783, class=0, nrcpts=1, msgid=<[email protected]>, proto=ESMTP, daemon=MTA, relay=mywebsitedomain.co.uk [127.0.0.1]
Sep 10 22:03:16 mail sendmail[2656]: u8AL3G7U002656: [email protected], ctladdr=apache (48/48), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=40690, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (u8AL3G7h002657 Message accepted for delivery)
Sep 10 22:03:16 mail sendmail[2658]: u8AL3G7h002657: to=root, ctladdr=<[email protected]> (48/48), delay=00:00:00, xdelay=00:00:00, mailer=local, pri=40996, dsn=2.0.0, stat=Sent
Sep 10 22:03:16 mail sendmail[2660]: u8AL3GQp002660: from=apache, size=10914, class=0, nrcpts=1, msgid=<[email protected]>, relay=apache@localhost
Sep 10 22:03:16 mail sendmail[2661]: u8AL3GB4002661: from=<[email protected]>, size=11007, class=0, nrcpts=1, msgid=<[email protected]>, proto=ESMTP, daemon=MTA, relay=mywebsitedomain.co.uk [127.0.0.1]
Sep 10 22:03:16 mail sendmail[2660]: u8AL3GQp002660: [email protected], ctladdr=apache (48/48), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=40914, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (u8AL3GB4002661 Message accepted for delivery)
Sep 10 22:03:16 mail sendmail[2663]: STARTTLS=client, relay=gmail-smtp-in.l.google.com., version=TLSv1/SSLv3, verify=FAIL, cipher=ECDHE-RSA-AES128-GCM-SHA256, bits=128/128
Sep 10 22:03:17 mail sendmail[2663]: u8AL3GB4002661: to=<[email protected]>, ctladdr=<[email protected]> (48/48), delay=00:00:01, xdelay=00:00:01, mailer=esmtp, pri=131007, relay=gmail-smtp-in.l.google.com. [64.233.166.26], dsn=2.0.0, stat=Sent (OK 1473541397 f23si8646501wmh.115 - gsmtp)

我的个人 Google 电子邮件地址成功收到了该电子邮件,但企业电子邮件端(由 Google Apps 托管)未收到其他订单确认。

我可以在电子邮件源中看到它(使用垃圾邮件测试网站)。

以下看起来是错误的:

[email protected];
Return-Path: [email protected]

上述情况是否是我没有收到电子邮件的原因,或者我是否错过了这里的情节?

编辑

我还必须补充一点,该网站尚未更新其 DNS 记录以指向新服务器。我目前正在使用 hosts 文件进行测试,并已更新 SPF 记录以允许新服务器使用包含 ip4 标记发送电子邮件。

答案1

答案2

通过安装 Postfix 并切换到它,这个问题就轻松解决了(感谢 rocket_doge_)帮助我做到这一点。

相关内容