audioplastic
Posts: 12
Joined: Tue Jan 15, 2013 12:51 am
Location: Cambridge

Strange RX/TX mangling when using SSH over wlan

Wed Mar 13, 2013 1:11 pm

Hi. I use my RPi headless. I have attached a wireless adapter to my RPi and assigned it a fixed IP, but the connection is really slow and flakey over SSH. The really strange thing happens when looking at the output of ifconfig. With my SSH connection over 192.168.1.101 (the fixed IP of the wireless adapter), making subsequent calls to ifconfig makes the RX value of the wlan adapter increase, and the TX value of the eth0 adapter increase. This suggests that packets are being received wirelessly and transmitted over wire. When I disconnect the wired connection, the wireless connection stops working. The eth0 adapter is set to a different IP, so I am totally baffled! Can anyone explain / remedy this bizarre situation?

Code: Select all

[email protected] ~ $ ifconfig
eth0      Link encap:Ethernet  HWaddr ***
          inet addr:192.168.1.100  Bcast:192.168.1.255  Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:170 errors:0 dropped:4 overruns:0 frame:0
          TX packets:214 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:16187 (15.8 KiB)  TX bytes:40106 (39.1 KiB)

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

wlan0     Link encap:Ethernet  HWaddr ***
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:116 errors:0 dropped:3 overruns:0 frame:0
          TX packets:9 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:13219 (12.9 KiB)  TX bytes:1032 (1.0 KiB)

User avatar
M.M
Posts: 107
Joined: Fri Aug 03, 2012 7:40 am
Location: Hamburg, GER

Re: Strange RX/TX mangling when using SSH over wlan

Wed Mar 13, 2013 3:53 pm

Hi audio,

if I interpret your post and ifconfig output correctly, your eth0 has 192.168.1.100 while wlan0 has 192.168.1.101. Given they are both connected to the same router/access point it looks like you have connected both interfaces to the same network.

Since they appear to have the same Metric (=priority) data that is supposed to go through wlan0 can end up at eth0 and vice versa. So data gets lost and your connection is flawed.


Regards,

M.M
"If people read the FAQs the Qs wouldn't be A F, would they?"

audioplastic
Posts: 12
Joined: Tue Jan 15, 2013 12:51 am
Location: Cambridge

Re: Strange RX/TX mangling when using SSH over wlan

Wed Mar 13, 2013 4:26 pm

You interpret the question correctly. Why doesn't this setup work? I know it is a little odd for one machine to have 2 ip on the same network, but it should still work, no?

User avatar
M.M
Posts: 107
Joined: Fri Aug 03, 2012 7:40 am
Location: Hamburg, GER

Re: Strange RX/TX mangling when using SSH over wlan

Wed Mar 13, 2013 10:10 pm

Hi audio,

there might be setups like this that work, but I would assume that in those scenarios at least the Metric of the interfaces is altered to define a preferred interface for the data to pass through. But that wouldn't help, because then, the other, non-preferred interface would basically be dead. The packets would always take the interface with the "better" metric, leaving the other one unemployed...

I do not know how far into network stuff you are, but ARP flux would be another issue with your setup.

To cut a long story short: To make this work you will have to invest some time. It's not going to work "plug-and-play-like".


Regards,


M.M
"If people read the FAQs the Qs wouldn't be A F, would they?"

Return to “Troubleshooting”