Solved FreeBSD Firewall Upload Speeds

I recently removed pfSense from my network and migrated my core firewall to "vanilla" FreeBSD. All NAT, routing, firewall, etc. functionality is handled by PF and I've been able to replace other desirable pfSense features (pfatt, pfBlockerNG, etc.) with custom scripts.

I have symmetrical 1G fiber and my download speeds are just fine (~900 Mbps+). However, I am not able to break ~500 Mbps up, which is irritating me as pfSense didn't have a problem with this. I am using the em(4) driver (Intel I210 Gigabit Network Connection) on FreeBSD 12.2 p5. Additionally, I have the following tunables configured in /boot/loader.conf:

net.isr.maxthreads="-1"
net.isr.bindthreads="1"


I've also added the following to /etc/sysctl.conf:

net.isr.dispatch=deferred

Without the above configuration settings, my download speed won't break ~500 Mbps, which is why I was thinking there might be a tunable that I am missing for tweaking upload speed. I've also come across many references to em(4) tunables specifically related to IGB, none of which seem to work any more since the IGB driver was integrated into the em(4) driver. I have searched and tried a number of other tunables but nothing seems to make a difference on my upload speed. I am happy to post any additional information, i.e. the contents of my /etc/pf.conf but since all routing is working normally, I figured this might be frivolous. Any assistance would be greatly appreciated.
 
Out of curiosity, why are you changing defaults at all?

With the tunables that I referenced above, my speeds basically double. Without those options set, I get ~500 Mbps up/down - with those options set, I get very close to a full 1Gbps up/down (~930 Mbps).
 
Back
Top