ubuntu网络设置

修改/etc/network/interfaces文件
sudo gedit /etc/network/interfaces

贴出我的eth0设置,自己看情况修改:
# The primary network interface
auto eth0
#iface eth0 inet dhcp
iface eth0 inet static
address 192.168.1.145(ip地址)
netmask 255.255.255.0(子网掩码)
gateway 192.168.1.1(网关)

iface eth0 inet static
address 192.168.0.10
netmask 255.255.255.0
gateway 192.168.0.1
posted @ 2016-07-25 08:11  shiningrise  阅读(178)  评论(0编辑  收藏  举报
// 侧边栏目录 // https://blog-static.cnblogs.com/files/douzujun/marvin.nav.my1502.css