查看所有网络设备:ifconfig -a
手动设置IP:ifconfig eth1 192.168.1.30 netmask 255.255.255.0
查看IP:ifconfig eth1
设置网关:route add default gw 192.168.1.111 eth1
查看网关:route -n
删除网关:route del default gw 192.168.1.111 eth1
查看网关:
DNS设置
编辑“etc/resolv.conf”添加:
nameserver 114.114.114.114
nameserver 8.8.8.8