从昨晚到现在使用MacOS访问国内网站均指向182.43.124.6这个ip的网页(
), 后来反应过来查看dns:
nslookup zhihu.com
Server: 1.1.1.1 Address: 1.1.1.1#53 Non-authoritative answer: Name: zhihu.com Address: 182.43.124.6
笔记本上的DNS Servers的1.1.1.1已经被投毒了,后续删除这个域名服务器(不知道之前是怎么加入进来的),同时清除域名缓存,到此虚惊一场。
MACOS 版本 | 使用的命令 |
---|---|
macOS 12 (Monterey) | sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder |
macOS 11 (Big Sur) | sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder |
macOS 10.15 (Catalina) | sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder |
macOS 10.14 (Mojave) | sudo killall -HUP mDNSResponder |
macOS 10.13 (High Sierra) | sudo killall -HUP mDNSResponder |
macOS 10.12 (Sierra) | sudo killall -HUP mDNSResponder |
OS X 10.11 (El Capitan) | sudo killall -HUP mDNSResponder |
OS X 10.10 (Yosemite) | sudo discoveryutil udnsflushcaches |
OS X 10.9 (Mavericks) | sudo killall -HUP mDNSResponder |
OS X 10.8 (Mountain Lion) | sudo killall -HUP mDNSResponder |
Mac OS X 10.7 (Lion) | sudo killall -HUP mDNSResponder |
Mac OS X 10.6 (Snow Leopard) | sudo dscacheutil -flushcache |
Mac OS X 10.5 (Leopard) | sudo lookupd -flushcache |
Mac OS X 10.4 (Tiger) | lookupd -flushcache |