Slow transfers over Wifi

Hi folks,

So, Im not really techy in terms of networking.. I have a Netgear DGN3500 running OpenWrt Chaos Calmer 15.05.1.

Every time I try to transfer somewhat large data (say movie files, 700 Mb, 1+TB) from my wired 100/10Mbps connected NAS over Wifi to either my Mac (using afpfs) or my Linux tower (using NFS) , it seems to take FOREVER ! And, while the transfer is being done, I can barely browse my NAS .. everything becomes unusable until the transfer is complete !

I am wondering if one could help me out troubleshoot this problem to see if it's something wrong with my router's configuration ? I took a few screenshots from the "realtime graphs" while copying data...

Is this normal !? Seems odd to me...

Much thanks in advance for any tips on how to troubleshoot this!

Pat

First of all the 15.05 is very old version. Upgrade to the latest one http://downloads.openwrt.org/releases/18.06.2/targets/lantiq/xway/openwrt-18.06.2-lantiq-xway-netgear_dgn3500-squashfs-sysupgrade.bin

Other than thatI suggest you use iperf to measure the speed between the hosts to verify the speed that LAN-to-WLAN can achieve and take out of the equation factors as hard disk speed.

We also need to have a look at the network and wireless configuration.
uci show network; uci show wireless; uci show firewall

3 Likes

Check you LAN port connection speed, if it is 10baseT (10Mbps) instead of 100 or 1000 that might explain it.

swconfig dev switch0 show | grep speed

OR

if your using Luci you can check under Network->Switch

All my speeds are at link: port:2 link:up speed:1000baseT full-duplex .... so that ain't it..

1 Like

What about the wireless speeds

iwinfo | grep -e Rate -e Mode -e Signal

if it is normal have a look at the stations. ( Don't post MAC addresses)

iw dev wlan0 station dump

or a quick summary of all stations:
iw dev wlan0 station dump | grep bitrate

2 Likes
root@router:~# iwinfo | grep -e Rate -e Mode -e Signal
          Mode: Master  Channel: 3 (2.422 GHz)
          Signal: -55 dBm  Noise: -95 dBm
          Bit Rate: 94.2 MBit/s
          Type: nl80211  HW Mode(s): 802.11bgn

Soo... bit rate normal here ?

1 Like

@Ravenlost, welcome to the community.

Don't waste your n00b post limit - use one post to respond to others, we can all read.

And this seems rather normal for a device with a likely bottleneck. With a 333 MHz processor trying to transfer at 1000 Mbps, that's not a far-fetched notion.

1 Like

I'd love to do the upgrade, but had a pretty hard time back then to get it working properly with my ADSL... Had to manually change so files (i.e. adsl.bin,etc), plus I've got quite a big setup in here (proxy, vpn, and other stuff)... Don't really feel like bitting the bullet (just yet) and spend to much time on it trying to get everything working ...

I've installed iperf as per your suggestion. Here are the results going from my Linux box --(wifi)--> router --(eth)--> NAS

Running iperf server on my NAS here, and client on Linux:

First, Bi-directional sequential test

[raven@Papounix ~]$ iperf -c 192.168.2.2 -r
------------------------------------------------------------
Server listening on TCP port 5001
TCP window size: 85.3 KByte (default)
------------------------------------------------------------
------------------------------------------------------------
Client connecting to 192.168.2.2, TCP port 5001
TCP window size:  110 KByte (default)
------------------------------------------------------------
[  5] local 192.168.2.183 port 60488 connected with 192.168.2.2 port 5001
[ ID] Interval       Transfer     Bandwidth
[  5]  0.0-10.3 sec  49.0 MBytes  40.0 Mbits/sec
[  4] local 192.168.2.183 port 5001 connected with 192.168.2.2 port 46441
[  4]  0.0-10.1 sec  32.6 MBytes  27.1 Mbits/sec

Second, Bi-directional simultaneous test

[raven@Papounix ~]$ iperf -c 192.168.2.2 -d
------------------------------------------------------------
Server listening on TCP port 5001
TCP window size: 85.3 KByte (default)
------------------------------------------------------------
------------------------------------------------------------
Client connecting to 192.168.2.2, TCP port 5001
TCP window size: 93.5 KByte (default)
------------------------------------------------------------
[  5] local 192.168.2.183 port 60500 connected with 192.168.2.2 port 5001
[  4] local 192.168.2.183 port 5001 connected with 192.168.2.2 port 48827
[ ID] Interval       Transfer     Bandwidth
[  5]  0.0-10.2 sec  38.5 MBytes  31.5 Mbits/sec
[  4]  0.0-10.7 sec  3.62 MBytes  2.84 Mbits/sec

Finally, here is my network and wireless config:

network.loopback=interface
network.loopback.ifname='lo'
network.loopback.proto='static'
network.loopback.ipaddr='127.0.0.1'
network.loopback.netmask='255.0.0.0'
network.globals=globals
network.lan=interface
network.lan.force_link='1'
network.lan.type='bridge'
network.lan.proto='static'
network.lan.netmask='255.255.255.0'
network.lan.ip6assign='60'
network.lan.ifname='eth0.1'
network.lan.ipaddr='192.168.2.1'
network.@switch[0]=switch
network.@switch[0].name='switch0'
network.@switch[0].reset='1'
network.@switch[0].enable_vlan='1'
network.@switch[0].mirror_source_port='0'
network.@switch[0].mirror_monitor_port='0'
network.@switch[0].enable_vlan4k='1'
network.@switch_vlan[0]=switch_vlan
network.@switch_vlan[0].device='switch0'
network.@switch_vlan[0].vlan='1'
network.@switch_vlan[0].ports='0 1 2 5t'
network.atm=atm-bridge
network.atm.encaps='llc'
network.atm.payload='bridged'
network.atm.vci='35'
network.atm.vpi='8'
network.wan=interface
network.wan.ifname='nas0'
network.wan.proto='pppoe'
network.wan.ipv6='1'
network.wan.username='USERNAME'
network.wan.password='PASSWORD'
network.wan.peerdns='0'
network.wan.dns='208.67.222.222 208.67.220.220'
network.wan6=interface
network.wan6.ifname='@wan'
network.wan6.proto='dhcpv6'
network.dsl=adsl
network.dsl.annex='mm'
network.dsl.firmware='/lib/firmware/adsl.bin'
network.vpn0=interface
network.vpn0.ifname='tun0'
network.vpn0.proto='none'
network.vpn0.auto='1'
network.@switch_vlan[1]=switch_vlan
network.@switch_vlan[1].device='switch0'
network.@switch_vlan[1].vlan='2'
network.@switch_vlan[1].ports='3 5t'
network.waneth=interface
network.waneth.proto='static'
network.waneth.ifname='eth0.2'
network.waneth.ipaddr='192.168.1.2'
network.waneth.netmask='255.255.255.0'
network.waneth.gateway='192.168.1.1'
network.waneth.dns='192.168.1.1'
wireless.radio0=wifi-device
wireless.radio0.type='mac80211'
wireless.radio0.hwmode='11g'
wireless.radio0.path='pci0000:00/0000:00:0e.0'
wireless.radio0.htmode='HT40'
wireless.radio0.txpower='16'
wireless.radio0.country='BE'
wireless.radio0.distance='7'
wireless.radio0.channel='3'
wireless.@wifi-iface[0]=wifi-iface
wireless.@wifi-iface[0].device='radio0'
wireless.@wifi-iface[0].network='lan'
wireless.@wifi-iface[0].mode='ap'
wireless.@wifi-iface[0].encryption='psk-mixed'
wireless.@wifi-iface[0].key='PASSWORD'
wireless.@wifi-iface[0].ssid='SSIDNAME'
firewall.@defaults[0]=defaults
firewall.@defaults[0].syn_flood='1'
firewall.@defaults[0].input='ACCEPT'
firewall.@defaults[0].output='ACCEPT'
firewall.@defaults[0].forward='REJECT'
firewall.@zone[0]=zone
firewall.@zone[0].name='lan'
firewall.@zone[0].input='ACCEPT'
firewall.@zone[0].output='ACCEPT'
firewall.@zone[0].forward='ACCEPT'
firewall.@zone[0].network='lan'
firewall.@zone[1]=zone
firewall.@zone[1].name='wan'
firewall.@zone[1].input='REJECT'
firewall.@zone[1].output='ACCEPT'
firewall.@zone[1].forward='REJECT'
firewall.@zone[1].masq='1'
firewall.@zone[1].mtu_fix='1'
firewall.@zone[1].network='wan wan6 waneth'
firewall.@forwarding[0]=forwarding
firewall.@forwarding[0].src='lan'
firewall.@forwarding[0].dest='wan'
firewall.@rule[0]=rule
firewall.@rule[0].name='Allow-DHCP-Renew'
firewall.@rule[0].src='wan'
firewall.@rule[0].proto='udp'
firewall.@rule[0].dest_port='68'
firewall.@rule[0].target='ACCEPT'
firewall.@rule[0].family='ipv4'
firewall.@rule[1]=rule
firewall.@rule[1].name='Allow-Ping'
firewall.@rule[1].src='wan'
firewall.@rule[1].proto='icmp'
firewall.@rule[1].icmp_type='echo-request'
firewall.@rule[1].family='ipv4'
firewall.@rule[1].target='ACCEPT'
firewall.@rule[2]=rule
firewall.@rule[2].name='Allow-IGMP'
firewall.@rule[2].src='wan'
firewall.@rule[2].proto='igmp'
firewall.@rule[2].family='ipv4'
firewall.@rule[2].target='ACCEPT'
firewall.@rule[3]=rule
firewall.@rule[3].name='Allow-DHCPv6'
firewall.@rule[3].src='wan'
firewall.@rule[3].proto='udp'
firewall.@rule[3].src_ip='fe80::/10'
firewall.@rule[3].src_port='547'
firewall.@rule[3].dest_ip='fe80::/10'
firewall.@rule[3].dest_port='546'
firewall.@rule[3].family='ipv6'
firewall.@rule[3].target='ACCEPT'
firewall.@rule[4]=rule
firewall.@rule[4].name='Allow-MLD'
firewall.@rule[4].src='wan'
firewall.@rule[4].proto='icmp'
firewall.@rule[4].src_ip='fe80::/10'
firewall.@rule[4].icmp_type='130/0' '131/0' '132/0' '143/0'
firewall.@rule[4].family='ipv6'
firewall.@rule[4].target='ACCEPT'
firewall.@rule[5]=rule
firewall.@rule[5].name='Allow-ICMPv6-Input'
firewall.@rule[5].src='wan'
firewall.@rule[5].proto='icmp'
firewall.@rule[5].icmp_type='echo-request' 'echo-reply' 'destination-unreachable' 'packet-too-big' 'time-exceeded' 'bad-header' 'unknown-header-type' 'router-solicitation' 'neighbour-solicitation' 'router-advertisement' 'neighbour-advertisement'
firewall.@rule[5].limit='1000/sec'
firewall.@rule[5].family='ipv6'
firewall.@rule[5].target='ACCEPT'
firewall.@rule[6]=rule
firewall.@rule[6].name='Allow-ICMPv6-Forward'
firewall.@rule[6].src='wan'
firewall.@rule[6].dest='*'
firewall.@rule[6].proto='icmp'
firewall.@rule[6].icmp_type='echo-request' 'echo-reply' 'destination-unreachable' 'packet-too-big' 'time-exceeded' 'bad-header' 'unknown-header-type'
firewall.@rule[6].limit='1000/sec'
firewall.@rule[6].family='ipv6'
firewall.@rule[6].target='ACCEPT'
firewall.@include[0]=include
firewall.@include[0].path='/etc/firewall.user'
firewall.@rule[7]=rule
firewall.@rule[7].src='wan'
firewall.@rule[7].dest='lan'
firewall.@rule[7].proto='esp'
firewall.@rule[7].target='ACCEPT'
firewall.@rule[8]=rule
firewall.@rule[8].src='wan'
firewall.@rule[8].dest='lan'
firewall.@rule[8].dest_port='500'
firewall.@rule[8].proto='udp'
firewall.@rule[8].target='ACCEPT'
firewall.@redirect[0]=redirect
firewall.@redirect[0].target='DNAT'
firewall.@redirect[0].src='wan'
firewall.@redirect[0].dest='lan'
firewall.@redirect[0].proto='tcp'
firewall.@redirect[0].src_dport='11000-11999'
firewall.@redirect[0].dest_ip='192.168.2.2'
firewall.@redirect[0].dest_port='11000-11999'
firewall.@redirect[0].name='NASTorrent'
firewall.@redirect[1]=redirect
firewall.@redirect[1].target='DNAT'
firewall.@redirect[1].src='wan'
firewall.@redirect[1].dest='lan'
firewall.@redirect[1].proto='tcp'
firewall.@redirect[1].dest_ip='192.168.2.2'
firewall.@redirect[1].dest_port='21'
firewall.@redirect[1].name='NASFTP'
firewall.@redirect[1].src_dport='21'
firewall.@redirect[2]=redirect
firewall.@redirect[2].name='HTTP Transparent Proxy Redirect'
firewall.@redirect[2].src='lan'
firewall.@redirect[2].proto='tcp'
firewall.@redirect[2].src_dport='80'
firewall.@redirect[2].src_dip='!192.168.2.1'
firewall.@redirect[2].dest_ip='192.168.2.1'
firewall.@redirect[2].dest='lan'
firewall.@redirect[2].dest_port='8118'
firewall.@redirect[3]=redirect
firewall.@redirect[3].name='HTTPS Transparent Proxy Redirect'
firewall.@redirect[3].src='lan'
firewall.@redirect[3].proto='tcp'
firewall.@redirect[3].src_dport='443'
firewall.@redirect[3].src_dip='!192.168.2.1'
firewall.@redirect[3].dest_ip='192.168.2.1'
firewall.@redirect[3].dest='lan'
firewall.@redirect[3].dest_port='8118'
firewall.@redirect[3].enabled='0'
firewall.@redirect[4]=redirect
firewall.@redirect[4].name='HTTP Proxy for VPN'
firewall.@redirect[4].src='vpn_corbeau'
firewall.@redirect[4].proto='tcp'
firewall.@redirect[4].src_dport='80'
firewall.@redirect[4].src_dip='!192.168.2.1'
firewall.@redirect[4].dest_ip='192.168.2.1'
firewall.@redirect[4].dest='lan'
firewall.@redirect[4].dest_port='8118'
firewall.@redirect[4].enabled='0'
firewall.Allow_OpenVPN_Inbound=rule
firewall.Allow_OpenVPN_Inbound.target='ACCEPT'
firewall.Allow_OpenVPN_Inbound.src='*'
firewall.Allow_OpenVPN_Inbound.dest_port='1194'
firewall.Allow_OpenVPN_Inbound.name='Allow_OpenVPN_Inbound'
firewall.Allow_OpenVPN_Inbound.proto='udp'
firewall.vpn_corbeau=zone
firewall.vpn_corbeau.name='vpn_corbeau'
firewall.vpn_corbeau.network='vpn0'
firewall.vpn_corbeau.input='ACCEPT'
firewall.vpn_corbeau.forward='REJECT'
firewall.vpn_corbeau.output='ACCEPT'
firewall.vpn_corbeau.masq='1'
firewall.vpn_corbeau_forwarding_lan_in=forwarding
firewall.vpn_corbeau_forwarding_lan_in.src='vpn_corbeau'
firewall.vpn_corbeau_forwarding_lan_in.dest='lan'
firewall.vpn_corbeau_forwarding_lan_out=forwarding
firewall.vpn_corbeau_forwarding_lan_out.src='lan'
firewall.vpn_corbeau_forwarding_lan_out.dest='vpn_corbeau'
firewall.vpn_corbeau_forwarding_wan=forwarding
firewall.vpn_corbeau_forwarding_wan.src='vpn_corbeau'
firewall.vpn_corbeau_forwarding_wan.dest='wan'
firewall.@redirect[5]=redirect
firewall.@redirect[5].target='DNAT'
firewall.@redirect[5].proto='tcp'
firewall.@redirect[5].src_dport='80'
firewall.@redirect[5].dest_ip='192.168.2.2'
firewall.@redirect[5].dest_port='80'
firewall.@redirect[5].src='wan'
firewall.@redirect[5].dest='lan'
firewall.@redirect[5].name='NASWeb'
firewall.@rule[9]=rule
firewall.@rule[9].src='lan'
firewall.@rule[9].dest='wan'
firewall.@rule[9].name='Block_Inet'
firewall.@rule[9].enabled='0'
firewall.@rule[9].target='REJECT'

You'll find I have a 2nd vlan which I needed to create in order to daisy chain this router to my new net provider's router. Mine didn't have a VDSL port (only ADSL!), but I still wanted to use mine for FW, etc. So in short, I converted one of my regular ETH port to an internet eth port. All of my local lan is connected to MY router. My provider's router only send internet to my router...

Regardless, I know this special setup of daisy chain has nothing to do with my problem, since I always had this problem even when I had only my router with my previous inet provider (using adsl). Plus, all my lan is on my router, and nothing is connected to the provider's as I said...

That's a lot of information.. Hope it's not too much to go through...

@ [lleachii] : sorry, you're right. I should of just send one reply. Apologies. So, you think the only bottle neck would be the CPU on my router ?

Thanks :slight_smile:

I would suggest to raise that a lot.
Other than that is looks like the network is able to pass more than the traffic that you see when transfering the files. You can experiment with the window size and reach better numbers, but anyway that is already evidence that wifi/switch is not the culprit here.

2 Likes

This is no longer necessary with current release. The install is clean. Don't keep settings when upgrading just make a note or copy and start from a clean install

Alright, perhaps I'll try an upgrade / fresh install of Openwrt later on next week, but for sure will backup everything up first. Can I always backtrack version if need be ?

Has for my wireless.radio0.distance='7', how much is "a lot" [trendy] ? Is this really gonna change anything ? I can try for the hell of it at say 15... ?

WOW, 15 is still too low...way too low!!!

If this is the Distance Optimization setting...you need to read this:

Especially this part:

I've also found that values < 100 do not work on OpenWrt.

Okay, well, before at distance 7, I had:

[raven@Papounix ~]$ iperf -c 192.168.2.2 -r -f MBytes
------------------------------------------------------------
Server listening on TCP port 5001
TCP window size: 0.08 MByte (default)
------------------------------------------------------------
------------------------------------------------------------
Client connecting to 192.168.2.2, TCP port 5001
TCP window size: 0.11 MByte (default)
------------------------------------------------------------
[  5] local 192.168.2.183 port 60640 connected with 192.168.2.2 port 5001
[ ID] Interval       Transfer     Bandwidth
[  5]  0.0-10.2 sec  26.4 MBytes  2.59 MBytes/sec
[  4] local 192.168.2.183 port 5001 connected with 192.168.2.2 port 58322
[  4]  0.0-10.1 sec  27.1 MBytes  2.69 MBytes/sec

I've placed in 100 as the distance in Luci, saved and applied. Redid the iperf test:

root@router:~# uci show wireless | grep distance
wireless.radio0.distance='100'

[raven@Papounix ~]$ iperf -c 192.168.2.2 -r -f MBytes
------------------------------------------------------------
Server listening on TCP port 5001
TCP window size: 0.08 MByte (default)
------------------------------------------------------------
------------------------------------------------------------
Client connecting to 192.168.2.2, TCP port 5001
TCP window size: 0.10 MByte (default)
------------------------------------------------------------
[  5] local 192.168.2.183 port 60798 connected with 192.168.2.2 port 5001
[ ID] Interval       Transfer     Bandwidth
[  5]  0.0-10.5 sec  30.8 MBytes  2.92 MBytes/sec
[  4] local 192.168.2.183 port 5001 connected with 192.168.2.2 port 34304
[  4]  0.0-10.1 sec  31.4 MBytes  3.11 MBytes/sec

About the same results. Would I need to perhaps reboot the router ?

No, they improved...but can you try this on Wired instead (to eliminate this as a wireless issue)???

If you Saved and Applied, no.

Yes.

Well, I was able to try a wired connection using my Macbook laptop. Here are the results from it:

macbook:~ raven$ iperf -c 192.168.2.2 -r -f MBytes
------------------------------------------------------------
Server listening on TCP port 5001
TCP window size: 0.12 MByte (default)
------------------------------------------------------------
------------------------------------------------------------
Client connecting to 192.168.2.2, TCP port 5001
TCP window size: 0.13 MByte (default)
------------------------------------------------------------
[  5] local 192.168.2.101 port 60919 connected with 192.168.2.2 port 5001
[ ID] Interval       Transfer     Bandwidth
[  5]  0.0-10.0 sec  1110 MBytes   111 MBytes/sec
[  5] local 192.168.2.101 port 5001 connected with 192.168.2.2 port 39666
[  5]  0.0-10.0 sec  1108 MBytes   111 MBytes/sec

Seems about 40x faster...

Should I just close this case and have the verdict to be: Nothing to do! Router's CPU is the limitation! ?

There is 10x rate difference in your wifi iperf test.

Apologies mbo2o: I don't understand what you mean, and I think its because I dont properly understand the output of iperf...

You are talking about the B-directrional simultaneous test I did earlier:

...
[  5]  0.0-10.2 sec  38.5 MBytes  31.5 Mbits/sec
[  4]  0.0-10.7 sec  3.62 MBytes  2.84 Mbits/sec

?

What do you mean by there's a There is 10x rate difference ? I see that you've simply divided 31.5 by 2.84, but do not understand why.... (again cause I dont understand output of iperf properly probably.)

I'd say wireless was the limitation. Your device has to send the packet across the bridge twice for WiFi, and 0 times for a LAN wired connection.

...and BTW, I totaled a ~36x improvement on wired over wireless.

Is that normal ? And how did you determined that ? Can I, and should I fix this ?

The iperf test is reporting the speed over consecutive ten second periods.

It seems to have started at around 38 then slowed down to 2.8

2.8 is similar to the speed achieved while transfering large files in your realtime graph. This suggests CPU bottleneck on your router.

1 Like