OPNsense Forum

English Forums => Hardware and Performance => Topic started by: pholt on March 30, 2024, 07:23:41 PM

Title: Performance Tuning
Post by: pholt on March 30, 2024, 07:23:41 PM
I just installed OPNsense on a Lenovo m920q with a dual interface NIC, 32GB of memory, and an i5-8600T CPU. Network throughput to the 1Gb WAN is about 50% of what it was with the ASUS router it replaced. Since I assume I have lots of power and memory, I also assume there are settings which I may need to adjust.

Does anyone have advice about how to get things back up to close to normal? Thank you!
Title: Re: Performance Tuning
Post by: Patrick M. Hausen on March 30, 2024, 08:11:12 PM
What sort of NIC?
Title: Re: Performance Tuning
Post by: pholt on March 30, 2024, 10:16:20 PM
It's a NIC with an Intel X540-BT2 chipset. It'll support 10Gb, but I only need 1Gb out of it at the moment.
Title: Re: Performance Tuning
Post by: pholt on April 03, 2024, 11:16:39 PM
I've been struggling with this and have been trying all kinds of tuneables to get things back to normal. Nothing was working. I just added the following to disable flow control:

dev.ix.0.fc = 0   
dev.ix.1.fc = 0

My interfaces are ix0 and ix1. As soon as I added these, my throughput doubled.
Title: Re: Performance Tuning
Post by: Seimus on April 05, 2024, 10:31:16 AM
By default BSD doesn't sent Pause Frames if Flow control is enabled. However it will accept Pause control from directly connected device, which can result in lower performance in regards of throughput.

Flow control is a feature that should guarantee a mitigation of packet loss and retransmission due to H/W buffer overflow (saturation). Basically if flow control is enabled device that is not able to keep the pacing will sent Pause frames and ask "please slow down".

Flow control should be never enabled between network devices, this feature is only supposed to be used on towards endpoints/host devices

Regards,
S.