2016 10 02 Ubuntu 常用网络设置 - huyx/1 GitHub Wiki

相关文件:

/etc/resolvconf/resolv.conf.d/base -- 设置 dns 服务器

ifconfig:

ifconfig
ifconfig -a
ifconfig eth0
ifconfig eth0 up    # ifup eth0
ifconfig eth0 down  # ifdown eth0
ifconfig eth0 192.168.1.180
ifconfig eth0 netmask 255.255.255.0
ifconfig eth0 172.16.25.125 netmask 255.255.255.224
ifconfig eth0 mtu 1000

ifconfig eth0:0 172.16.25.127
ifconfig eth0:0

route:

route add default gw 192.168.1.1
route del default gw 192.168.1.1