OPNsense Forum

English Forums => Hardware and Performance => Topic started by: hushcoden on June 03, 2023, 05:00:23 pm

Title: Adding a tuneable ?
Post by: hushcoden on June 03, 2023, 05:00:23 pm
I'm testing the RSS with i225 (igc) and before enabling that the net.inet.rss.bits value was 2 (it's a 4-core/4-thread CPU), but after enabling RSS the net.inet.rss.bits was set to '3', how come?

And should I leave it to 3 or should I add a tunable and set net.inet.rss.bits=2 ?

Tia.
Title: Re: Adding a tuneable ?
Post by: Seimus on June 09, 2023, 10:22:57 pm
Hard to say why it changed. But refferencing the OPNsense Guide

https://docs.opnsense.org/troubleshooting/performance.html


Furthermore, the RSS implementation also provides a few necessary sysctls:

    net.inet.rss.enabled = 1

Makes sure RSS is enabled. This is disabled by default to prevent regressions on NICs that do not properly implement the RSS interface.

    net.inet.rss.bits = X

This one is dependent on the amount of cores you have. By default the amount of bits here represent the amount of cores x 2 in binary. This is done on purpose to provide load-balancing, though there is no current implementation for this so we recommend setting this value to the amount of bits representing the number of CPU cores. This means we use the following values:

    for 4-core systems, use ‘2’

    for 8-core systems, use ‘3’

    for 16-core systems, use ‘4’

    Etc.
Title: Re: Adding a tuneable ?
Post by: hushcoden on June 10, 2023, 05:24:15 pm
Thanks, so I added the tunable net.inet.rss.bits=2