我正在尝试在我的局域网中为 ipv6 设置反向 DNS。应委派的 DNS 服务器位于 2001:5c0:1400:b::9,而 RDNS 应工作的主机位于 2001:5c0:1500:300::1。问题是,除非指定 +trace,否则 dig -x 似乎不起作用:
$ dig -x 2001:5c0:1500:300::1
; <<>> DiG 9.9.5-3-Ubuntu <<>> -x 2001:5c0:1500:300::1
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: SERVFAIL, id: 24545
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.3.0.0.0.5.1.0.c.5.0.1.0.0.2.ip6.arpa. IN PTR
;; Query time: 714 msec
;; SERVER: 192.168.0.1#53(192.168.0.1)
;; WHEN: Sun Oct 19 23:31:58 CEST 2014
;; MSG SIZE rcvd: 101
$ dig -x 2001:5c0:1500:300::1 +trace
; <<>> DiG 9.9.5-3-Ubuntu <<>> -x 2001:5c0:1500:300::1 +trace
;; global options: +cmd
. 433182 IN NS l.root-servers.net.
. 433182 IN NS a.root-servers.net.
. 433182 IN NS f.root-servers.net.
. 433182 IN NS c.root-servers.net.
. 433182 IN NS h.root-servers.net.
. 433182 IN NS i.root-servers.net.
. 433182 IN NS g.root-servers.net.
. 433182 IN NS e.root-servers.net.
. 433182 IN NS b.root-servers.net.
. 433182 IN NS j.root-servers.net.
. 433182 IN NS k.root-servers.net.
. 433182 IN NS d.root-servers.net.
. 433182 IN NS m.root-servers.net.
. 435889 IN RRSIG NS 8 0 518400 20141025170000 20141018160000 22603 . kvgfN/rC3esMrbGF3KZFrwogm1EKA+nwZrFMXHf3a9sJsDZdpe4iDrOB 0xKyu9dvcsdfLcVLDMHGojlQqUAOda9KIcOGIdeFXl3IOKAk91XvQfrq mLOz02vrBog6gfFnzA34lGkLan1BtRFqKkjxvIHUyIcxstZkak44p/2/ t1w=
;; Received 913 bytes from 192.168.0.1#53(192.168.0.1) in 369 ms
ip6.arpa. 172800 IN NS d.ip6-servers.arpa.
ip6.arpa. 172800 IN NS b.ip6-servers.arpa.
ip6.arpa. 172800 IN NS c.ip6-servers.arpa.
ip6.arpa. 172800 IN NS e.ip6-servers.arpa.
ip6.arpa. 172800 IN NS f.ip6-servers.arpa.
ip6.arpa. 172800 IN NS a.ip6-servers.arpa.
ip6.arpa. 86400 IN DS 13880 8 2 068554EFCB5861F42AF93EF8E79C442A86C16FC5652E6B6D2419ED52 7F344D17
ip6.arpa. 86400 IN RRSIG DS 8 2 86400 20141026190000 20141019180000 10069 arpa. oRqujHjYlEPu3LNM61WtGMXvMyXYYxvBnTPxYLhZxs3rZxqLNaqmzMQr 5cGjUBoEPbAQSsSvpXBX/VHKRf0FjcpL1kXt6YcmzwMyMKdlQrC9Rrxz AQd1csbsfpJP6E6AwWz3Vbd/AnsghIk+BRKerC2+DxjCxU8UpV9ae/3v R0o=
;; Received 685 bytes from 192.33.4.12#53(c.root-servers.net) in 77 ms
1.0.c.5.0.1.0.0.2.ip6.arpa. 86400 IN NS ns2.gogo6.com.
1.0.c.5.0.1.0.0.2.ip6.arpa. 86400 IN NS ns1.gogo6.com.
1.0.c.5.0.1.0.0.2.ip6.arpa. 10800 IN NSEC 8.c.5.0.1.0.0.2.ip6.arpa. NS RRSIG NSEC
1.0.c.5.0.1.0.0.2.ip6.arpa. 10800 IN RRSIG NSEC 5 11 10800 20141102202721 20141019192721 49851 5.0.1.0.0.2.ip6.arpa. GVMC0TF/hNZGCCRXY4bvpvuyqtmqC5mqhVp0DGhxldJ0m64CVzmOcFMf S3aqoggYRPMYqHNKG4Zjg40/IlwXSdsLmTmOQgBu0OBR4tJBGuomqoTP 7BsXeKx0a3Vgz/8mdz1Nf8e4czGWwkCAo/AomluyWKdEDM5bQiX30Uqa e0k=
;; Received 372 bytes from 2001:dc0:2001:a:4608::59#53(e.ip6-servers.arpa) in 373 ms
3.0.0.0.5.1.0.c.5.0.1.0.0.2.ip6.arpa. 3600 IN NS wonderland.broker.freenet6.net.
;; Received 173 bytes from 72.55.143.215#53(ns1.gogo6.com) in 125 ms
1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.3.0.0.0.5.1.0.c.5.0.1.0.0.2.ip6.arpa. 3600 IN PTR wonderland.broker.freenet6.net.
;; Received 128 bytes from 2001:5c0:1400:b::9#53(wonderland.broker.freenet6.net) in 0 ms
我也尝试过在线工具http://www.sput.nl/internet/ipv6/chkip6rev.html他们确实报告了 SERVFAIL。我等了一天,想看看这是否是某些缓存的影响,但问题仍然存在。这里可能发生了什么?
答案1
对于此委托中的某些 DNS 解析器,它将失败:
3.0.0.0.5.1.0.c.5.0.1.0.0.2.ip6.arpa. 3600 IN NS wonderland.broker.freenet6.net.
DNS 服务器wonderland.broker.freenet6.net
仅有 IPv6 地址:
$ host wonderland.broker.freenet6.net
wonderland.broker.freenet6.net has IPv6 address 2001:5c0:1400:b::9
当您这样做dig
时,您是在要求您配置的 DNS 解析器为您解析地址。如果该解析器没有 IPv6,那么它将无法遵循此委派,因为它无法到达仅 IPv6 的 DNS 服务器。当您这样做时,dig +trace
您将自己完成所有解析。如果您的系统有 IPv6,那么它可以遵循整个链。在没有 IPv6 的系统上,解析也会失败。
在这种情况下,问题(也?)似乎与 的权威 DNS 服务器中的错误有关2001:5c0:1400:b::9
。它发送的答案不符合 DNS 标准。根据RFC 1034原始问题必须包含在响应中。但是,您的 DNS 服务器发送了一个空的问题部分(BIND 将其报告为“问题太多”,尽管从技术上讲是“问题不够”,!= 1
我猜是匹配的):
Domain Name System (response)
Transaction ID: 0xad20
Flags: 0x8400 Standard query response, No error
Questions: 0
Answer RRs: 1
Authority RRs: 0
Additional RRs: 0
Answers
1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.3.0.0.0.5.1.0.c.5.0.1.0.0.2.ip6.arpa:
type PTR, class IN, wonderland.broker.freenet6.net
所以基本上您的权威 DNS 服务器已损坏,并且dig
它不会关心,但‘真正的’ DNS 解析器会关心……