使用dig调试dns的疑惑随记2020-07-09

来自三线的随记

环境:vmware net

多个dns server现象一样

➤ dig 1.baidu.com @202.141.162.123  -p5353 
;; Question section mismatch: got 1.baidu.com/A/CLASS32769
➤ dig -v
DiG 9.10.3-P4-Ubuntu
➤ dpkg -l dnsutils
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name                               Version                Architecture           Description
+++-==================================-======================-======================-==========================================================================
ii  dnsutils                           1:9.10.3.dfsg.P4-8ubun amd64                  Clients provided with BIND


起初以为是EDNS问题,看了一下这个server应该不支持EDNS,也是这样

➤ kdig 1.baidu.com @202.141.162.123  -p5353 
;; WARNING: query/response question sections are different
;; ->>HEADER<<- opcode: QUERY; status: SERVFAIL; id: 40182
;; Flags: qr rd ra; QUERY: 1; ANSWER: 0; AUTHORITY: 0; ADDITIONAL: 0

;; QUESTION SECTION:
;; 1.baidu.com.        		CLASS32769	A

;; Received 29 B
;; Time 2020-07-09 01:30:37 CST
;; From 202.141.162.123@5353(UDP) in 48.5 ms


可以看到出现了个CLASS32769信息,且kdig 报WARNING: query/response question sections are different


后面找了一台centos测试同一个DNS节点表现正常

[root@centos ~]# dig -v
DiG 9.11.4-P2-RedHat-9.11.4-9.P2.el7