ubuntu network is unreachable解决办法
2013-12-09 20:38
316 查看
版本:ubuntu10.04 之前使用的是动态分配IP,网络突然就不行了,改为静态分配IP。
配置静态IP地址
sudo vi /etc/network/interfaces
内容如下:
auto lo
iface lo inet loopback
auto eth1
#iface eth1 inet dhcp 动态分配
iface eth1 inet static
address 192.168.1.8
netmask 255.255.255.0
network 192.168.1.0
broadcast 192.168.1.255
gateway 192.168.1.1
配置DNS
vi /etc/resolv.conf
增加内容:
nameserver 192.168.1.1
naserver 202.106.0.20
配置网关
route add default gw 192.168.1.1
重新启动网络配置
/etc/init.d/networking restart 重启配置
配置静态IP地址
sudo vi /etc/network/interfaces
内容如下:
auto lo
iface lo inet loopback
auto eth1
#iface eth1 inet dhcp 动态分配
iface eth1 inet static
address 192.168.1.8
netmask 255.255.255.0
network 192.168.1.0
broadcast 192.168.1.255
gateway 192.168.1.1
配置DNS
vi /etc/resolv.conf
增加内容:
nameserver 192.168.1.1
naserver 202.106.0.20
配置网关
route add default gw 192.168.1.1
重新启动网络配置
/etc/init.d/networking restart 重启配置
相关文章推荐
- 解决ubuntu下ftp登录错误:do_ypcall: clnt_call: RPC: Unable to send; errno = Network is unreachable
- .ubuntu network is unreachable 解决记
- network is unreachable 网关PING不通解决办法
- ubuntu network is unreachable 解决记
- ”ssh: connect to host gmail.com port 22: Network is unreachable"的解决办法
- ubuntu network is unreachable 解决记
- ubuntu network is unreachable 解决记
- ubuntu network is unreachable 解决记
- ubuntu network is unreachable 解决记
- connect network is unreachable 解决办法
- Ubuntu network is unreachable解决方法
- vmware linux ubuntu network information(静态和动态桥接以前可以上的,现在都不能上网解决办法)
- connect:Network is unreachable error 解决方法
- ubuntu 12.04 遇到sudo: /etc/sudoers is mode 0777 , should be 0440的解决办法
- Ubuntu 设置固定ip,NetWork-Manager不能保存固定ip解决办法
- Scene is unreachable due to lack of entry points and does not have an identifier for runtime access via -instantiateViewControllerWithIdentifier解决办法
- 使用javamail出现java.net.SocketException: Network is unreachable: connect异常 解决方法
- 关于"connect: network is unreachable" 及 虚拟机主机共享文件夹创建失败问题的解决
- ubuntu network connection 消失的解决办法
- Ubuntu network is unreachable