连接显示,但未加载任何内容(DNS 解析失败)

连接显示,但未加载任何内容(DNS 解析失败)

无线驱动程序已安装,NetworkManager 正在工作,但 Firefox/任何 OTA 上都不会加载任何内容

wlan0 出现,内置无线卡,通过设置 - 网络,它说我已无线连接,但互联网上不会加载任何内容。即使连接到以太网也是如此。

eth0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
    ether 3c:07:54:3c:08:3a  txqueuelen 1000  (Ethernet)
    RX packets 0  bytes 0 (0.0 B)
    RX errors 0  dropped 0  overruns 0  frame 0
    TX packets 0  bytes 0 (0.0 B)
    TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
    device interrupt 16  

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
    inet 127.0.0.1  netmask 255.0.0.0
    inet6 ::1  prefixlen 128  scopeid 0x10<host>
    loop  txqueuelen 1  (Local Loopback)
    RX packets 24  bytes 1664 (1.6 KiB)
    RX errors 0  dropped 0  overruns 0  frame 0
    TX packets 24  bytes 1664 (1.6 KiB)
    TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

wlan0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
    inet 192.168.1.53  netmask 255.255.255.0  broadcast 192.168.1.255
    inet6 fe80::dd5b:7d61:4623:70a  prefixlen 64  scopeid 0x20<link>
    ether b8:8d:12:2d:fc:82  txqueuelen 1000  (Ethernet)
    RX packets 376  bytes 84045 (82.0 KiB)
    RX errors 0  dropped 0  overruns 0  frame 0
    TX packets 85  bytes 11346 (11.0 KiB)
    TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

ping facebook.com

ping: facebook.com: Temporary failure in name resolution

ping 31.13.81.36

PING 31.13.81.36 (31.13.81.36) 56(84) bytes of data.
64 bytes from 31.13.81.36: icmp_seq=2 ttl=84 time=40.1 ms
64 bytes from 31.13.81.36: icmp_seq=3 ttl=84 time=41.4 ms
64 bytes from 31.13.81.36: icmp_seq=4 ttl=84 time=41.9 ms
64 bytes from 31.13.81.36: icmp_seq=5 ttl=84 time=40.5 ms
64 bytes from 31.13.81.36: icmp_seq=6 ttl=84 time=40.3 ms
64 bytes from 31.13.81.36: icmp_seq=7 ttl=84 time=39.2 ms
^C
--- 31.13.81.36 ping statistics ---
7 packets transmitted, 6 received, 14% packet loss, time 6032ms
rtt min/avg/max/mdev = 39.294/40.613/41.901/0.874 ms

答案1

您的互联网连接正常,如 所示ping 31.13.81.36。缺少的是 DNS 名称查找,这就是ping facebook.com失败的原因。我无法解释为什么你什么都没有,/etc/resolv.conf但这应该可以让你开始。

/etc/resolv.conf以此作为合理的起点来创造缺失

nameserver 8.8.8.8
nameserver 8.8.4.4

相关内容