如何同时激活eth0和wlan0以通过终端发送请求

时间:2015-08-21 06:28:49

标签: curl networking

这是我的路线表

Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface default 192.168.1.1 0.0.0.0 UG 0 0 0 eth0 10.1.1.0 * 255.255.255.0 U 9 0 0 wlan0 192.168.1.0 * 255.255.255.0 U 1 0 0 eth0

我正在尝试为wlan0添加不同的网关,以便我可以通过wlan0和指定的网关发出一些请求,而不会使用此命令影响eth0

route add -n 10.1.1.0 gw 10.1.1.1 netmask 255.255.255.0 dev wlan0

但是现有的没有更新它正在添加新的

Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface default 192.168.1.1 0.0.0.0 UG 0 0 0 eth0 10.1.1.0 10.1.1.1 255.255.255.0 UG 0 0 0 wlan0 10.1.1.0 * 255.255.255.0 U 9 0 0 wlan0 192.168.1.0 * 255.255.255.0 U 1 0 0 eth0

因此,我无法专门使用wlan0发送任何请求curl,因为即使在指定eth0

之后,curl仍会--interface wlan0发送请求

0 个答案:

没有答案