几周前开始出现这种情况,时断时续。访问 google.com、Facebook.com 后又会出现这种情况
This site can’t be reached
www.google.com’s server IP address could not be found.
即使我当天早些时候在现场,也会发生这种情况。有时启动路由器或笔记本电脑可以解决问题,但并非总是如此。有时,经过一夜的放置后,它会重新开始工作。
执行 nslookup 或 dig 返回:
jeffreyschwartz@jeffreys-MacBook-Pro:/usr/bin$ nslookup google.com
;; Warning: Message parser reports malformed message packet.
Server: 1.1.1.1
Address: 1.1.1.1#53
Non-authoritative answer:
Name: google.com
Address: \# 4 ACD907AE
jeffreyschwartz@jeffreys-MacBook-Pro:/usr/bin$ dig google.com
;; Warning: Message parser reports malformed message packet.
; <<>> DiG 9.10.6 <<>> google.com
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 29237
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 0
;; WARNING: Message has 26875 extra bytes at end
;; QUESTION SECTION:
;google.com. IN A
;; ANSWER SECTION:
google.com. 30825 RESERVED0 A \# 4 ACD907AE
;; Query time: 42 msec
;; SERVER: 1.1.1.1#53(1.1.1.1)
;; WHEN: Mon Apr 13 18:53:28 EDT 2020
;; MSG SIZE rcvd: 26929
清除缓存sudo dscacheutil -flushcache;sudo killall -HUP mDNSResponder;
说cache flushed
没有帮助。
我发现其他一些命令可能有用。
scutil --dns
DNS configuration
resolver #1
search domain[0] : fios-router.home
nameserver[0] : 1.1.1.1
nameserver[1] : 8.8.8.8
nameserver[2] : 192.168.1.1
nameserver[3] : 1.0.0.1
flags : Request A records
reach : 0x00000002 (Reachable)
resolver #2
domain : local
options : mdns
timeout : 5
flags : Request A records
reach : 0x00000000 (Not Reachable)
order : 300000
resolver #3
domain : 254.169.in-addr.arpa
options : mdns
timeout : 5
flags : Request A records
reach : 0x00000000 (Not Reachable)
order : 300200
resolver #4
domain : 8.e.f.ip6.arpa
options : mdns
timeout : 5
flags : Request A records
reach : 0x00000000 (Not Reachable)
order : 300400
resolver #5
domain : 9.e.f.ip6.arpa
options : mdns
timeout : 5
flags : Request A records
reach : 0x00000000 (Not Reachable)
order : 300600
resolver #6
domain : a.e.f.ip6.arpa
options : mdns
timeout : 5
flags : Request A records
reach : 0x00000000 (Not Reachable)
order : 300800
resolver #7
domain : b.e.f.ip6.arpa
options : mdns
timeout : 5
flags : Request A records
reach : 0x00000000 (Not Reachable)
order : 301000
DNS configuration (for scoped queries)
resolver #1
search domain[0] : fios-router.home
nameserver[0] : 1.1.1.1
nameserver[1] : 8.8.8.8
nameserver[2] : 192.168.1.1
nameserver[3] : 1.0.0.1
if_index : 5 (en0)
flags : Scoped, Request A records
reach : 0x00000002 (Reachable)
jeffreyschwartz@jeffreys-MacBook-Pro:/usr/bin$
jeffreyschwartz@jeffreys-MacBook-Pro:/usr/bin$ dns-sd -G v4 google.com
DATE: ---Mon 13 Apr 2020---
19:01:39.457 ...STARTING...
Timestamp A/R Flags if Hostname Address TTL
19:01:40.531 Add 2 0 google.com. 0.0.0.0 77 No Such Record
^C
jeffreyschwartz@jeffreys-MacBook-Pro:/usr/bin$ dns-sd -V
Currently running daemon (system service) is version 880.70.3
dscacheutil -q host -a name google.com
name: google.com
ipv6_address: 2607:f8b0:4004:800::200e
该问题发生在 Safari、Google Chrome 和 Brave 中。macOS 是 Mojave v10.14.6 (18G4032)。所有其他软件都已更新。
根据需要,我还可以提供 wireshark 或其他信息。