I thought I had a nice rpi4 router set up, but I've discovered that the throughput is crap. From any device, rpi4 included, I can do a speedtest and show a 130mbps connection to the internet. with rpi4 in the way, this nosedives to around 10mbps.

rpi4 is set up as a simple router on stick, in and out through eth0, which is running at a gig happily as ethtool confirms. Again... i can grab stuff just fine from the raspberry pi itself, it's only when traffic goes through it it goes massively south!

For the routing setup, it's purely just got ip_forward enabled and a MASQ iptables line. No meaningful CPU load is seen when being routed through.

What I have noticed from a tcdpump to compare the two scenarios from a client on my network, is that when grabbing an image from the net, the pi gets back a 11000 byte packet or such, but then as it returns the packet back to the actual client, it splits it down to 8 1514 byte frames. Feels like this could be the problem, but I am struggling to find anything meaningful about how to stop this fragmentation being done.

Screenshot of tcpdump if relevant - https://imgur.com/a/fUjEAd3

  • Can you be precise with your speeds, please. When you write "mbps" do you actually mean "Mb/s" or "MB/s"? Given that 100 Mb/s is 10 MB/s it's really important to get the units correct. – roaima Sep 13 '19 at 19:29