Azure DNS 区域中的子域:CNAME 而不是 NS

Subdomain in Azure DNS Zone: CNAME instead of NS

我在 webs.com 购买了一个域(这里我称之为 contoso.com),然后我将它委托给了我的 Azure contoso.com 区域 DNS。后来我创建了一个子域(例如 sub.contoso.com)来发布一个托管在 Azure VM 中的新网站。出于这个原因,我创建了一个 CNAME 记录到 link sub.contoso.com 到 Azure VM 的默认 DNS(类似于 xxxx.westeurope.cloudapp.azure.com)。它工作得很好,但几次后我发现了这个 guide 并且为了测试,我按照指南中的描述更改了我的 DNS 配置(简而言之,我创建了一个名为 sub.contoso.com 的新区域 DNS 和然后我在 contoso.com 区域中添加了 NS 记录)。它可以工作,但是,因为我需要创建另外两个子域,这个配置看起来太复杂了,我更喜欢前一个。但是,这是我的问题,我不明白针对 NS 使用 CNAME 记录是否会导致性能或安全性方面的一些差异。

谢谢

在这种情况下,主要区别在于这些记录托管在单独的区域中。一个在父域 contoso.com 的父区域中托管,另一个在子域 sub.contoso.com 的子区域中托管。记录量大时便于记录管理

The Domain Name System is a hierarchy of domains. The hierarchy starts from the 'root' domain, whose name is simply '.'. Below this come top-level domains, such as 'com', 'net', 'org', 'uk' or 'jp'. Below these top-level domains are second-level domains, such as 'org.uk' or 'co.jp'. And so on. The domains in the DNS hierarchy are hosted using separate DNS zones. These zones are globally distributed, hosted by DNS name servers around the world.

DNS zone - A domain is a unique name in the Domain Name System, for example 'contoso.com'. A DNS zone is used to host the DNS records for a particular domain. For example, the domain 'contoso.com' may contain several DNS records such as 'mail.contoso.com' (for a mail server) and 'www.contoso.com' (for a website).

对于正常的 DNS 查询过程,父区域中的记录比子区域中的记录更容易得到回答。您可以看到 DNS 查询示例和 how DNS delegation works.