Ativei minha eth0 com fio e wifi eth2 com o gerenciador de rede (ambos dhcp):
$ route -n Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface 192.168.1.0 0.0.0.0 255.255.255.0 U 1 0 0 eth0 192.168.1.0 0.0.0.0 255.255.255.0 U 2 0 0 eth2 169.254.0.0 0.0.0.0 255.255.0.0 U 1000 0 0 eth0 0.0.0.0 192.168.1.1 0.0.0.0 UG 0 0 0 eth0
tcpdump -n -i eth0
mostra tráfego, enquanto tcpdump -n -i eth2
não.
Então, vamos tentar reordenar as interfaces na tabela de roteamento:
sudo route del -net 192.168.1.0/24 dev eth2 sudo route add -net 192.168.1.0/24 dev eth2 sudo route -n add default gw 192.168.1.1 dev eth2
Agora, a tabela de roteamento é:
Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface 192.168.1.0 0.0.0.0 255.255.255.0 U 0 0 0 eth2 192.168.1.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0 169.254.0.0 0.0.0.0 255.255.0.0 U 1000 0 0 eth0 0.0.0.0 192.168.1.1 0.0.0.0 UG 0 0 0 eth2 0.0.0.0 192.168.1.1 0.0.0.0 UG 0 0 0 eth0
agora o tcpdump mostra todo o tráfego que passa pela interface eth2.