为什么 dig +trace 不能持续显示相同数量的记录?

为什么 dig +trace 不能持续显示相同数量的记录?

我正在运行 Debian,在运行 dig 时遇到不一致的行为。

dig @8.8.8.8 +trace +nodnssec www.harvard.edu我连续运行该命令几次,每次都得到不同的答案。

其中一个结果是:

; <<>> DiG 9.17.19-1-Debian <<>> @8.8.8.8 +trace +nodnssec www.harvard.edu
; (1 server found)
;; global options: +cmd
.           41344   IN  NS  a.root-servers.net.
.           41344   IN  NS  b.root-servers.net.
.           41344   IN  NS  c.root-servers.net.
.           41344   IN  NS  d.root-servers.net.
.           41344   IN  NS  e.root-servers.net.
.           41344   IN  NS  f.root-servers.net.
.           41344   IN  NS  g.root-servers.net.
.           41344   IN  NS  h.root-servers.net.
.           41344   IN  NS  i.root-servers.net.
.           41344   IN  NS  j.root-servers.net.
.           41344   IN  NS  k.root-servers.net.
.           41344   IN  NS  l.root-servers.net.
.           41344   IN  NS  m.root-servers.net.
;; Received 239 bytes from 8.8.8.8#53(8.8.8.8) in 19 ms

另一个结果是:

; <<>> DiG 9.17.19-1-Debian <<>> @8.8.8.8 +trace +nodnssec www.harvard.edu
; (1 server found)
;; global options: +cmd
.           40314   IN  NS  a.root-servers.net.
.           40314   IN  NS  b.root-servers.net.
.           40314   IN  NS  c.root-servers.net.
.           40314   IN  NS  d.root-servers.net.
.           40314   IN  NS  e.root-servers.net.
.           40314   IN  NS  f.root-servers.net.
.           40314   IN  NS  g.root-servers.net.
.           40314   IN  NS  h.root-servers.net.
.           40314   IN  NS  i.root-servers.net.
.           40314   IN  NS  j.root-servers.net.
.           40314   IN  NS  k.root-servers.net.
.           40314   IN  NS  l.root-servers.net.
.           40314   IN  NS  m.root-servers.net.
;; Received 239 bytes from 8.8.8.8#53(8.8.8.8) in 19 ms

edu.            172800  IN  NS  a.edu-servers.net.
edu.            172800  IN  NS  b.edu-servers.net.
edu.            172800  IN  NS  c.edu-servers.net.
edu.            172800  IN  NS  d.edu-servers.net.
edu.            172800  IN  NS  e.edu-servers.net.
edu.            172800  IN  NS  f.edu-servers.net.
edu.            172800  IN  NS  g.edu-servers.net.
edu.            172800  IN  NS  h.edu-servers.net.
edu.            172800  IN  NS  i.edu-servers.net.
edu.            172800  IN  NS  j.edu-servers.net.
edu.            172800  IN  NS  k.edu-servers.net.
edu.            172800  IN  NS  l.edu-servers.net.
edu.            172800  IN  NS  m.edu-servers.net.
;; Received 839 bytes from 198.97.190.53#53(h.root-servers.net) in 35 ms

第三个结果是:

; <<>> DiG 9.17.19-1-Debian <<>> @8.8.8.8 +trace +nodnssec www.harvard.edu
; (1 server found)
;; global options: +cmd
.           40306   IN  NS  a.root-servers.net.
.           40306   IN  NS  b.root-servers.net.
.           40306   IN  NS  c.root-servers.net.
.           40306   IN  NS  d.root-servers.net.
.           40306   IN  NS  e.root-servers.net.
.           40306   IN  NS  f.root-servers.net.
.           40306   IN  NS  g.root-servers.net.
.           40306   IN  NS  h.root-servers.net.
.           40306   IN  NS  i.root-servers.net.
.           40306   IN  NS  j.root-servers.net.
.           40306   IN  NS  k.root-servers.net.
.           40306   IN  NS  l.root-servers.net.
.           40306   IN  NS  m.root-servers.net.
;; Received 239 bytes from 8.8.8.8#53(8.8.8.8) in 19 ms

edu.            172800  IN  NS  e.edu-servers.net.
edu.            172800  IN  NS  d.edu-servers.net.
edu.            172800  IN  NS  k.edu-servers.net.
edu.            172800  IN  NS  f.edu-servers.net.
edu.            172800  IN  NS  m.edu-servers.net.
edu.            172800  IN  NS  i.edu-servers.net.
edu.            172800  IN  NS  j.edu-servers.net.
edu.            172800  IN  NS  h.edu-servers.net.
edu.            172800  IN  NS  b.edu-servers.net.
edu.            172800  IN  NS  l.edu-servers.net.
edu.            172800  IN  NS  c.edu-servers.net.
edu.            172800  IN  NS  g.edu-servers.net.
edu.            172800  IN  NS  a.edu-servers.net.
;; Received 867 bytes from 192.33.4.12#53(c.root-servers.net) in 31 ms

harvard.edu.        172800  IN  NS  ext-dns-1.harvard.edu.
harvard.edu.        172800  IN  NS  ext-dns-2.harvard.edu.
;; Received 124 bytes from 192.35.51.30#53(f.edu-servers.net) in 31 ms

www.harvard.edu.    10800   IN  CNAME   pantheon-systems.map.fastly.net.
;; Received 117 bytes from 128.103.200.162#53(ext-dns-2.harvard.edu) in 39 ms

第三个结果正是我所期望的。为什么每次我都得不到这个结果?使用 8.8.8.8 以外的其他名称服务器似乎无关紧要。似乎通常在我看到 CNAME 记录之前结果就被截断了?

lsb_release -ds产量Debian GNU/Linux bookworm/sid

相关内容