资源记录集类型CNAME DNS名称foo.com的。在先端不允许在区bar.com [英] RRSet of type CNAME with DNS name foo.com. is not permitted at apex in zone bar.com

查看:834
本文介绍了资源记录集类型CNAME DNS名称foo.com的。在先端不允许在区bar.com的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的 foo.com bar.com 。我无论在Route53管理。 foo.com 主机我的网站,我想直接流量从 bar.com foo.com 。我试图建立一个 CNAME 记录 bar.com 指向 foo.com ,但我得到的错误信息:

I own foo.com and bar.com. I am managing both in Route53. foo.com hosts my site, and I'd like to direct traffic from bar.com to foo.com. I tried to set up a CNAME record for bar.com pointing to foo.com, but I got the error message:

RRSet of type CNAME with DNS name foo.com. is not permitted at apex in zone bar.com.

为什么不是这个工作,我能做些什么呢?

Why doesn't this work, and what can I do instead?

推荐答案

根据RFC1912第2.4节:

As per RFC1912 section 2.4:

 A CNAME record is not allowed to coexist with any other data.  In
 other words, if suzy.podunk.xx is an alias for sue.podunk.xx, you
 can't also have an MX record for suzy.podunk.edu, or an A record, or
 even a TXT record.  Especially do not try to combine CNAMEs and NS 
 records like this!:

           podunk.xx.      IN      NS      ns1
                           IN      NS      ns2
                           IN      CNAME   mary
           mary            IN      A

在RFC非常有意义。名称不能被一些真正的,但同时是一个别名,别的东西。 bar.com 是一个区域,因此它含蓄地具有对 bar.com 名称的SOA记录。你不能同时拥有一个SOA记录,并具有相同名称的CNAME。

The RFC makes perfect sense. A name can't be something "real" but at the same time be an alias for something else. bar.com is a zone therefore it implicitly has an SOA record for the bar.com name. You can't have both a SOA record and a CNAME with the same name.

尽管RFC是有道理的,这些情况下,您希望提供一个CNAME在此区域的顶点的现象相当普遍。这就是为什么干线53提供了别名记录。这是一个53路特定扩展DNS它们提供您所需要的确切功能。看一看<一href="http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/CreatingAliasRRSets.html">http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/CreatingAliasRRSets.html

Even though the RFC makes sense, these situations where you want to provide a CNAME at the zone's apex are quite common. That's why Route 53 provides alias records. These are a Route 53 specific extension to DNS which offer the exact functionality you require. Have a look at http://docs.aws.amazon.com/Route53/latest/DeveloperGuide/CreatingAliasRRSets.html

这篇关于资源记录集类型CNAME DNS名称foo.com的。在先端不允许在区bar.com的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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