在我的 centos7 虚拟机上,hostname
说bmargulies-centos7
,domainname
说(none)
,dig bmargulies-centos7
说下面的内容,并且该主机名的 ping 挂起。 IP地址从哪里来92.242.140.21
?
; <<>> DiG 9.9.4-RedHat-9.9.4-29.el7_2.3 <<>> bmargulies-centos7
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 55643
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:
; MBZ: 0005 , udp: 4096
;; QUESTION SECTION:
;bmargulies-centos7. IN A
;; ANSWER SECTION: bmargulies-centos7. 5 IN A 92.242.140.21
;; Query time: 29 msec
;; SERVER: 192.168.74.2#53(192.168.74.2)
;; WHEN: Sat May 21 14:04:49 EDT 2016
;; MSG SIZE rcvd: 63
答案1
它来自提供商的内部 DNS 服务器(地址为 192.168.74.2)。
该 DNS 服务器很可能已配置,/etc/resolv.conf
除非您已bind
在计算机上运行。