UP / HOME

Low throughput over LAN on Wi-Fi

I've been streaming media from my computer over LAN & it's been slow. I finally tested it today & the average speed was around 300 KB/s. This is when sending data from computer to phone over SSH while both are connected to router via Wi-Fi.

Both devices were on 2.4 GHz band & close to the router. I tested the same with another laptop & the speed averaged around 1.5 MB/s. This laptop was sitting in another room.

When I connect the computer with Ethernet cable it averages around 10 MB/s. And when I connect the computer on 5 GHz to router it averages around 1 MB/s. 1 MB/s is fine for my work so I'll just leave it like this.

I ran iperf3 on computer, both server & client. Averages around 55 MB/s. I didn't find iperf3 client on Android so couldn't run it on phone.

[ ID] Interval           Transfer     Bitrate
[  5]   0.00-10.00  sec   527 MBytes   442 Mbits/sec                  sender
[  5]   0.00-10.00  sec   527 MBytes   442 Mbits/sec                  receiver

2020-10-24

Things work at > 2 MB/s on average. I tested this with a 100 MB file.

andinus@ ~>dd if=/dev/urandom of=/home/andinus/test.file bs=1m count=100
100+0 records in
100+0 records out
104857600 bytes transferred in 3.801 secs (27581619 bytes/sec)

andinus ~> rsync /home/andinus/test.file  phone:/storage/emulated/0/
sending incremental file list
test.file
    104,857,600 100%    2.31MB/s    0:00:43 (xfr#1, to-chk=0/1)

sent 104,883,302 bytes  received 35 bytes  2,356,928.92 bytes/sec
total size is 104,857,600  speedup is 1.00

This changed after OpenBSD 6.8 update.

Also, this issue was only on LAN because the Internet throughput was higher than 300 KB/s which meant I could transfer files faster by transferring it over the Internet.

This reminds me of the story someone told me long ago on some IRC channel. Back when the Internet used to be slow, at times it was faster to browse through Tor. Because Tor nodes were run by Universities which large connections. I don't recall it completely so I might be forgetting something. Maybe it was something like this:

User ------------------------------------------------------ Destination
          |                                                 |
          ----- University ===== fast connection ============

-> = fast connection
-> - slow connection

I still don't understand though because if the limiting factor is user's connection then it shouldn't help, same for limiting factor being the destination's connection. But here we are assuming there is no packet loss, maybe back then the loss was significant which means that this setup would actually be faster than direct connection:

User -------------------------------------------------------------------- Destination
          |                                                                |
          ----- University ===== fast connection ============ University 2 =

-> = fast connection
-> - slow connection

Here "University 2" is close to the Destination which means less packet loss for it, assuming loss increases proportional to distance. This might get the file faster through Tor.

Andinus / 2020-10-07 / Modified: 2020-10-24 Sat 02:10 Emacs 27.1 (Org mode 9.4)