Wireguard is slow

Started by Andreiva, May 19, 2023, 03:41:09 PM

Previous topic - Next topic
Hi! I have an issue with my site to site wireguard vpn between OPNSense and Openwrt and that is slow speed, I get around 20mbps while I get at least 300mbps both upload and download at both sites. A client connecting directly just to the OPNSense vpn experiences the same speed. I have tried bigger and smaller MTUs with no meaningful change. Also both wireguard-kmod and wireguard-go offer the same performance. CPU usage isn't over 50%...

How are you testing performance?

May 21, 2023, 03:42:25 PM #2 Last Edit: May 21, 2023, 03:46:39 PM by Andreiva
With iperf3 server on the opnsense machine and client on my desktop at the other site, same thing happens if iperf3 server runs on a pc connected to opnsense

CPU not going over 50% is no sure indicator that it is not too slow for this application. Did you try iperf with -P8?

It is a common misconception to think that full bandwidth can be achieved with only one connection - much more true if that one thread runs on one core that is too slow to handle encryption. That being said, Wireguard is less taxing on CPU than any other VPN software and does not even need AES-NI acceleration.
Intel N100, 4 x I226-V, 16 GByte, 256 GByte NVME, ZTE F6005

1100 down / 770 up, Bufferbloat A

Tried with -P8, still limited to under 20mbps.

Did you manage to find the culprit?