1.设置静态IP
root@mfleat-K43SJ:~# cat /etc/network/interfaces
# interfaces(5) file used by ifup(8) and ifdown(8)
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet static
address 192.168.100.6
gateway 192.168.100.1
netmask 255.255.255.0
2.网关设置(最后发现网络不通是没有网关,不知道怎么没的。。)
route add default gw 192.168.100.1
route -n / netstat -r
3.设置DNS
root@mfleat-K43SJ:~# cat /etc/resolvconf/resolv.conf.d/base
nameserver 8.8.8.8