Port-arm archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: genet0 speeds under NetBSD/aarch64 on Rpi4 8 GB using UEFI/ACPI v1.17 firmware



> Finally, adding -w 227k can cause a big difference in
> performance. Testing right now I've seen everything from .3% (342Mbit
> vs 341Mbit) to roughly a 33% increase (410Mbit vs 310Mbit) when adding
> -w 227k on the client side. That's a large a window as you can set on
> NetBSD, FreeBSD, and Linux (maybe 227k is the largest the application
> supports, I don't know).

I know the answer to iperf3's support, and it supports much more
than this!  However, to use more than about 250KB socket buffers
on NetBSD, you need to tweak the settings for the network stack.
My workstation's /etc/sysctl.conf contains

kern.sbmax=1048576
net.inet6.tcp6.sendbuf_max=1048576
net.inet6.tcp6.recvbuf_max=1048576
net.inet.tcp.sendbuf_max=1048576
net.inet.tcp.recvbuf_max=1048576
net.inet.tcp.congctl.selected=cubic

(somehow, NetBSD doesn't accept iperf3's request for 1MB socket
buffers with these settings, only up to around 810KB), and
changes the congestion control algorithm to be somewhat more
aggressive than the otherwise default "newreno".

With this, I easily get 720Mbit/s to a remote host over a 9ms RTT
path using a PC with an Intel 1Gbit/s networking card.

BTW, manually overriding the window settings to iperf3 with "-w"
can be counter-productive, NetBSD has code to automatically
adjust the window size (default "on"), ref. "sysctl -a" output:

net.inet.tcp.recvbuf_auto = 1
net.inet.tcp.sendbuf_auto = 1
net.inet6.tcp6.recvbuf_auto = 1
net.inet6.tcp6.sendbuf_auto = 1

Regards,

- Håvard


Home | Main Index | Thread Index | Old Index