我的网络上有一个静态IP 地址。
我可以 ping Google 的其中一台服务器:
root@napajohn:~# ping 74.125.224.72
PING 74.125.224.72 (74.125.224.72) 56(84) bytes of data.
64 bytes from 74.125.224.72: icmp_req=2 ttl=49 time=76.5 ms
64 bytes from 74.125.224.72: icmp_req=3 ttl=49 time=75.6 ms
64 bytes from 74.125.224.72: icmp_req=4 ttl=49 time=76.6 ms
64 bytes from 74.125.224.72: icmp_req=5 ttl=49 time=76.6 ms
Run Code Online (Sandbox Code Playgroud)
但我无法解析任何主机名:
root@napajohn:~# ping www.google.com
ping: unknown host www.google.com
Run Code Online (Sandbox Code Playgroud)
我应该注意到我在代理后面,但这不应该影响不解析名称。我也无法解析我的代理名称。
这些是我的 /etc/hosts 文件的内容:
root@napajohn:~# cat /etc/hosts
127.0.0.1 localhost
::1 localhost ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
127.0.0.1 …
Run Code Online (Sandbox Code Playgroud) 当我遇到这个问题时,我试图安装其他东西。所以我尝试安装apt-utils来解决它。但是我无法安装 apt-utils,因为我的控制台告诉我我没有 apt-utils:
root@napajohn:~# apt-get install apt-utils
Reading package lists... Done
Building dependency tree... Done
The following NEW packages will be installed:
apt-utils
0 upgraded, 1 newly installed, 0 to remove and 28 not upgraded.
3 not fully installed or removed.
Need to get 0 B/129 kB of archives.
After this operation, 365 kB of additional disk space will be used.
WARNING: The following packages cannot be authenticated!
apt-utils
Install these packages without verification [y/N]? y
debconf: delaying package configuration, …
Run Code Online (Sandbox Code Playgroud)