机器名:bogon
两张网卡,一张有线eth0,一张无线网卡wlan
内网参数:169.0.199.24, 255.255.0.0 169.0.0.254
外网参数:192.168.1.117 255.255.255.0 192.168.1.1
操作:
1、增加路由参数:
route add 169.0.199.24 gw 169.0.0.254 eth0
route add 192.168.1.117 gw 192.168.1.1 wlan0
2、先删除墨认路由,因为默认路由是走内网出品的。(反正要先判断一下,看是否)
route del default
3、增加默认路由走外网出口
route add default gw 192.168.1.1 wlan0
route:
169.0.199.24 169.0.0.254 255.255.255.255 UGH 0 0 0 eth0
192.168.1.0 * 255.255.255.0 U 2 0 0 wlan0
192.168.122.0 * 255.255.255.0 U 0 0 0 virbr0 169.0.0.0 * 255.255.0.0 U 1 0 0 eth0 default bogon 0.0.0.0 UG 0 0 0 wlan0 default bogon 0.0.0.0 UG 0 0 0 wlan0