AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / server / 问题 / 765418
Accepted
JeremyCanfield
JeremyCanfield
Asked: 2016-03-23 11:22:18 +0800 CST2016-03-23 11:22:18 +0800 CST 2016-03-23 11:22:18 +0800 CST

绑定 DNS nslookup NXDOMAIN

  • 772

我在 IP 192.168.0.30 上的 Linux CentOS 上的 LAN 中安装了 BIND DNS 服务器。我还在 IP 192.168.0.23 上的 Linux Centos 上的 LAN 中安装了 HTTPD Web 服务器。我的 /etc/named.conf 文件配置为使用 /etc/forward.example.com 区域文件。

zone "example.com" IN {
 type master;
 file "/etc/forward.example.com";
 allow-update { none; };
};

按照CentOS 部署指南第 16.3 章中的说明,我在我的 BIND 转发区域文件中有以下内容,以创建到 HTTPD Web 服务器的 IP 地址的 A 记录,并将 CNAME 映射到 HTTPD Web 服务器。

$ORIGIN example.com.
$TTL 1D
@ IN SOA  ns1.example.com. hostmaster.example.com. (
                            2016032200 ; serial
                            1D         ; refresh
                            1H         ; retry
                            1W         ; expire
                            3H         ; minimum
)
@            IN      NS         ns1.example.com.
ns1          IN      A          192.168.0.30

server1      IN      A          192.168.0.23
www          IN      CNAME      server1

named-checkzone 命令生成 OK,从而确保 forward.example.com 区域文件正常。

[root@DNS1 ~]# named-checkzone example.com /etc/forward.example.com
zone example.com/IN: loaded serial 2016032200
OK

运行命令nslookup ns1.example.com会产生以下输出。这很好。

Server:     192.168.0.30
Address:    192.168.0.30#53

Name:       ns1.example.com
Address:    192.168.0.30

运行命令nslookup www.example.com会产生以下输出。

Server:     192.168.0.30
Address:    192.168.0.30#53

** server can't find www.example.com: NXDOMAIN

运行命令nslookup server1.example.com会产生以下输出。

Server:     192.168.0.30
Address:    192.168.0.30#53

** server can't find www.example.com: NXDOMAIN

我没有在 named.run 文件中看到错误。

[root@DNS1 ~]# tail /var/named/data/named.run

zone 0.in-addr.arpa/IN:          loaded serial 0
zone localhost/IN:               loaded serial 0
zone 1.0.0.127.in-addr.arpa/IN:  loaded serial 0
zone 0.168.192.in-addr.arpa/IN:  loaded serial 0
zone 1.xxxxxxxxxxx.ip6.arpa/IN:  loaded serial 0
zone example.com/IN:             loaded serial 0
zone localhost.localdomain/IN:   loaded serial 0
all zones loaded
running

搜索 serverfault.com 和 google.com,我无法确定为什么会收到 NXDOMAIN 错误。如果有任何提示或建议,我当然会很感激!

domain-name-system
  • 1 1 个回答
  • 14956 Views

1 个回答

  • Voted
  1. Best Answer
    Andrew B
    2016-03-23T11:43:24+08:002016-03-23T11:43:24+08:00

    你的序列号很可疑。

    0 ; serial
    

    您很可能没有修改序列号,并且您的辅助服务器没有复制添加www记录存在的更改。

    如果那实际上不是您的序列号,那么这个问题就被删掉了。:)

    • 2

相关问题

  • Solaris DNS

  • resolv.conf 在经过一段时间后被更改

  • 为什么有些网站的网址中没有“www”就无法显示?[关闭]

  • 为本地网络中的名称解析添加自定义 dns 条目

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    新安装后 postgres 的默认超级用户用户名/密码是什么?

    • 5 个回答
  • Marko Smith

    SFTP 使用什么端口?

    • 6 个回答
  • Marko Smith

    命令行列出 Windows Active Directory 组中的用户?

    • 9 个回答
  • Marko Smith

    什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同?

    • 3 个回答
  • Marko Smith

    如何确定bash变量是否为空?

    • 15 个回答
  • Martin Hope
    Tom Feiner 如何按大小对 du -h 输出进行排序 2009-02-26 05:42:42 +0800 CST
  • Martin Hope
    Noah Goodrich 什么是 Pem 文件,它与其他 OpenSSL 生成的密钥文件格式有何不同? 2009-05-19 18:24:42 +0800 CST
  • Martin Hope
    Brent 如何确定bash变量是否为空? 2009-05-13 09:54:48 +0800 CST
  • Martin Hope
    cletus 您如何找到在 Windows 中打开文件的进程? 2009-05-01 16:47:16 +0800 CST

热门标签

linux nginx windows networking ubuntu domain-name-system amazon-web-services active-directory apache-2.4 ssh

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve