1. 配置静态IP
#sudo vi /etc/network/interfaces
//eth0 动态获取
auto eth0
iface eth0 inet dhcp
//eth1 静态配置
auto eth1
iface eth1 inet static
address 192.168.2.192
gateway 192.168.2.1
netmask 255.255.255.0
broadcast 192.168.2.255
保存退出
2.重启 network
#sudo /etc/init.d/networking restart
3.查看IP设置
#sudo ifconfig