AWS EC2反向DNS(PTR)失败 [英] AWS EC2 Reverse DNS (PTR) Failing

查看:281
本文介绍了AWS EC2反向DNS(PTR)失败的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

搜索遍地,找不到答案.

Have searched everywhere, can't find answer.

我拥有域mydomain.com.根目录和www记录指向运行我的网站的主服务器.

I have the domain mydomain.com. The root and www records point to my main server, which runs my website.

我现在正在使用一个单独的AWS ec2实例来为我的域设置电子邮件服务器.该文件正在子域 mail 上运行.

I am now using a separate AWS ec2 instance to set up an email server for my domain. This is running on the subdomain mail.

我的dns看起来像这样:

My dns looks like this:

A @ webserverip
A www webserverip
A mail ec2ip

为防止服务器被标记为垃圾邮件,我在此处提交了亚马逊反向DNS表单: https://aws.amazon.com/forms/ec2-email-limit-rdns-request

To prevent my server from getting flagged for spam, I submitted the amazon reverse dns form here: https://aws.amazon.com/forms/ec2-email-limit-rdns-request

我给了他们ec2邮件服务器的IP,然后将"mail.mydomain.com"放在在"EIP 1的反向DNS记录"中,框.

I gave them the ip of my ec2 mail server, and put "mail.mydomain.com" in the "Reverse DNS Record for EIP 1" box.

但是,我一直收到他们的回信,说:

However, I keep receiving emails back from them saying:

当尝试映射反向DNS条目时,我们注意到这失败了,因为PTR记录与该域的A记录不匹配.

When attempting to map the reverse DNS entry, we notice that this is failing because the PTR record doesn't match the A record for that domain.

我们当前需要转发A记录来匹配所有反向DNS条目的PTR记录.

We currently require the forward A record to match the PTR record for all reverse DNS entries.

我真的不明白我在做什么错. 邮件"消息子域有一个指向我的ec2服务器ip的A记录.任何帮助将不胜感激!

I really don't understand what I am doing wrong. The "mail" subdomain has an A record pointing to my ec2 server ip. Any assistance would be greatly appreciated!

(如果这有任何区别,我正在为我的dns使用cloudflare)

(I am using cloudflare for my dns if this makes any difference)

推荐答案

您可以按照以下步骤在AWS上为EC2专用邮件服务器配置DNS:

You can follow these steps to configure the DNS for your EC2 dedicated mail server on AWS:

STEPS

  1. pop.mydomain.com添加两个 A 主机记录,并 smtp.mydomain.com指向您的弹性IP并分配您的 MX 记录到smtp.mydomain.com主机.
  2. mail.mydomain.com添加一个 CNAME 记录(不是 A 主机记录),该记录指向AWS分配的DNS条目(例如,ec2-XXX-XXX-XXX-XXX.REGION.compute.amazonaws.com).
  3. li>
  4. 提交您的rDNS请求,以将smtp.mydomain.com映射到您的EIP.
  5. 不要忘记为您的邮件服务器添加SPF TXT 记录.例如, v = spf1 mx a
  1. Add two A host records for pop.mydomain.com and smtp.mydomain.com that point to your elastic IP and assign your MX record to the smtp.mydomain.com host.
  2. Add a CNAME record (not A host record) for mail.mydomain.com that points to the DNS entry assigned by AWS (e.g., ec2-XXX-XXX-XXX-XXX.REGION.compute.amazonaws.com).
  3. Submit your rDNS request for smtp.mydomain.com mapping to your EIP.
  4. Don't forget to add the SPF TXT record for your mail server. For example, v=spf1 mx a

完成此设置后,就DNS而言,您应该具有正确的邮件服务器配置,该配置将通过SMTP测试并避免被标记为垃圾邮件.

Once you're done with this setup, you should have a proper mail server configuration in terms of DNS that would pass SMTP tests and avoids being flagged as spam.

这篇关于AWS EC2反向DNS(PTR)失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆