$ sudo apt update
Err:1 https://dl.google.com/linux/chrome/deb stable InRelease
System error resolving 'dl.google.com:https' - getaddrinfo (16: Device or resource busy)
Err:2 https://deb.nodesource.com/node_17.x focal InRelease
System error resolving 'deb.nodesource.com:https' - getaddrinfo (16: Device or resource busy)
Err:3 http://in.archive.ubuntu.com/ubuntu focal InRelease
System error resolving 'in.archive.ubuntu.com:http' - getaddrinfo (16: Device or resource busy)
Err:4 http://archive.canonical.com/ubuntu focal InRelease
System error resolving 'archive.canonical.com:http' - getaddrinfo (16: Device or resource busy)
Err:5 http://packages.microsoft.com/repos/code stable InRelease
System error resolving 'packages.microsoft.com:http' - getaddrinfo (16: Device or resource busy)
Err:6 http://in.archive.ubuntu.com/ubuntu focal-security InRelease
System error resolving 'in.archive.ubuntu.com:http' - getaddrinfo (16: Device or resource busy)
Err:7 http://in.archive.ubuntu.com/ubuntu focal-updates InRelease
System error resolving 'in.archive.ubuntu.com:http' - getaddrinfo (16: Device or resource busy)
Reading package lists... Done
Building dependency tree
Reading state information... Done
All packages are up to date.
when i did the ping command, i got this error
$ ping in.archive.ubuntu.com
ping: in.archive.ubuntu.com: System error
$ ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: enp2s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
link/ether 50:7b:9d:be:a1:6b brd ff:ff:ff:ff:ff:ff
inet 192.168.29.10/24 brd 192.168.29.255 scope global dynamic noprefixroute enp2s0
valid_lft 3080sec preferred_lft 3080sec
inet6 2405:201:f00e:fc33:ee4a:3b33:ee94:448/64 scope global temporary dynamic
valid_lft 3598sec preferred_lft 3598sec
inet6 2405:201:f00e:fc33:545a:f3a:a9b3:399/64 scope global dynamic mngtmpaddr noprefixroute
valid_lft 3598sec preferred_lft 3598sec
inet6 fe80::d88a:d74d:877e:a217/64 scope link noprefixroute
valid_lft forever preferred_lft forever
3: wlp3s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
link/ether a8:a7:95:8b:47:7b brd ff:ff:ff:ff:ff:ff
inet 192.168.29.250/24 brd 192.168.29.255 scope global dynamic noprefixroute wlp3s0
valid_lft 2985sec preferred_lft 2985sec
inet6 2405:201:f00e:fc33:cbde:8518:cc78:7dc1/64 scope global temporary dynamic
valid_lft 3598sec preferred_lft 3598sec
inet6 2405:201:f00e:fc33:bd35:f850:cace:fc3/64 scope global dynamic mngtmpaddr noprefixroute
valid_lft 3598sec preferred_lft 3598sec
inet6 fe80::e4d4:1c01:e8ab:2d5d/64 scope link noprefixroute
valid_lft forever preferred_lft forever
$ ifconfig
enp2s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.29.10 netmask 255.255.255.0 broadcast 192.168.29.255
inet6 2405:201:f00e:fc33:ee4a:3b33:ee94:448 prefixlen 64 scopeid 0x0<global>
inet6 2405:201:f00e:fc33:545a:f3a:a9b3:399 prefixlen 64 scopeid 0x0<global>
inet6 fe80::d88a:d74d:877e:a217 prefixlen 64 scopeid 0x20<link>
ether 50:7b:9d:be:a1:6b txqueuelen 1000 (Ethernet)
RX packets 18251 bytes 17958928 (17.9 MB)
RX errors 0 dropped 468 overruns 0 frame 0
TX packets 9382 bytes 1918435 (1.9 MB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
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 1000 (Local Loopback)
RX packets 5329 bytes 579810 (579.8 KB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 5329 bytes 579810 (579.8 KB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
wlp3s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.29.250 netmask 255.255.255.0 broadcast 192.168.29.255
inet6 2405:201:f00e:fc33:cbde:8518:cc78:7dc1 prefixlen 64 scopeid 0x0<global>
inet6 fe80::e4d4:1c01:e8ab:2d5d prefixlen 64 scopeid 0x20<link>
inet6 2405:201:f00e:fc33:bd35:f850:cace:fc3 prefixlen 64 scopeid 0x0<global>
ether a8:a7:95:8b:47:7b txqueuelen 1000 (Ethernet)
RX packets 678294 bytes 684218185 (684.2 MB)
RX errors 0 dropped 24508 overruns 0 frame 0
TX packets 317517 bytes 73388064 (73.3 MB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
答案1
根据您的数据,您的文件/etc/nsswitch.conf
可能在“hosts”行中包含无效条目。其他人观察到,“wins”需要 winbind 才能运行这里, A类似问题还显示了如何进一步检查。
因此,您需要检查您的nsswitch.conf
和您的resolv.conf
,并查阅手册页(man nsswitch.conf
),了解这些主机条目是否有效,或者它们可能需要哪些额外的服务。
本文ping
描述了和之间的区别nslookup
:ping 检查你的“解析”是否正常工作,而 nslookup 检查你的 DNS 是否正常工作
如果你找不到解决方案,请尝试使用strace
上面提到的链接获取有关问题的更多信息