更改名称服务器后子域不起作用 [英] Subdomain not working after changing the nameservers

查看:14
本文介绍了更改名称服务器后子域不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在 Microsoft Azure 中托管了我的网站.我已从 register.com 购买了域.

I have hosted my website in Microsoft Azure. I have purchased the domain from register.com.

我使用 Linux VM 进行项目部署.

I have used a Linux VM for my project deployment.

假设我的网站名称是 example.com.我为它创建了一个名为 app.example.com

Suppose my website name is example.com. I have created a sub domain for it called app.example.com

它工作正常,但当我在我的 azure 帐户中创建 DNS 区域资源时它不起作用在我的 register.com 站点中更新了这些名称服务器名称.

It was working fine but its not working when i created a DNS Zone resource in my azure account & updated those nameserver name in my register.com site.

推荐答案

根据您的描述,我们可以按照以下步骤设置 Azure DNS 区域和您的域名:
1. 通过 azure 门户添加记录集,指向您的 Azure VM:

According to your description, we can follow those steps to setup Azure DNS zone and your domain name:
1. Add record set via azure portal, point to your Azure VM:

2.将NS记录添加到register.com,如下:

2.Add NS record to register.com, like this:

Host: web.jasonye.com  
Record type:     NS record  
Value:    ns1-01.azure-dns.com 

几分钟后,我们可以使用nslookup验证名称解析是否有效:

After a few mins, we can use nslookup to verify name resoution is working or not:

nslookup -type=SOA jasonye.com

以下是来自上述命令的示例响应:

The following is an example response from the preceding command:

C:Users>nslookup -type=SOA jasonye.com
Server:  UnKnown
Address:  2404:f801:10:12e:fe::2

Non-authoritative answer:
jasonye.com
        primary name server = ns1-01.azure-dns.com
        responsible mail addr = azuredns-hostmaster.microsoft.com
        serial  = 1
        refresh = 3600 (1 hour)
        retry   = 300 (5 mins)
        expire  = 2419200 (28 days)
        default TTL = 300 (5 mins)

ns1-01.azure-dns.com    internet address = 40.90.4.1

之后,我们就可以通过IE访问这个网页了:

After that, we can access this web via IE:

有关 Azure DNS 区域的更多信息,请查看此 链接.

More information about Azure DNS zone, please check this link.

每个注册商都有自己的DNS管理工具来更改名称域的服务器记录.在注册商的 DNS 管理页面中,编辑 NS 记录并将 NS 记录替换为 Azure DNS已创建.

Each registrar has their own DNS management tools to change the name server records for a domain. In the registrar's DNS management page, edit the NS records and replace the NS records with the ones Azure DNS created.

这篇关于更改名称服务器后子域不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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