配置文件为: /etc/network/interfaces
默认为dhcp配置
auto eth0 
iface eth0 inet dhcp 
 
 
 手动设置ip,mask,gw
auto eth0 
iface eth0 inet static 
address 192.168.1.55 
netmask 255.255.255.0 
gateway 192.168.1.1 
 
  
 dns在 /etc/resolv.conf中,
 添加 nameserver xxx.xxx.xxx.xxx
 
 重启服务生效
/etc/init.d/networking restart