我正在使用 Ubuntu 12.04。
我的/etc/network/interfaces文件包括:
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface
auto eth0
iface eth0 inet static
address 192.168.1.58
gateway 192.168.1.1
network 192.168.1.0
broadcast 192.168.1.255
dns-nameservers 66.212.63.228 66.212.48.10
Run Code Online (Sandbox Code Playgroud)
我运行了命令: /etc/init.d/networking restart
其中回应:
*Running /etc/init.d/networking restart is deprecated because it may not enable again some interfaces
*Reconfiguring network interfaces...
RTNETLINK answers: File exists
Failed to bring up eth0
[ OK ]
Run Code Online (Sandbox Code Playgroud)
接下来我运行 ping google.com 并收到:
ping: unknown host google.com
Run Code Online (Sandbox Code Playgroud)
我不确定我的界面是否刷新了。如何使用静态 …
dns ×1