Bug 2222860
| Summary: | setting n-handler-threads didn't work | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux Fast Datapath | Reporter: | mhou <mhou> |
| Component: | openvswitch | Assignee: | Michael Santana <msantana> |
| openvswitch sub component: | daemons and tools | QA Contact: | mhou <mhou> |
| Status: | NEW --- | Docs Contact: | |
| Severity: | high | ||
| Priority: | unspecified | CC: | ctrautma, fleitner, jhsiao, kzhang, msantana |
| Version: | RHEL 8.0 | ||
| Target Milestone: | --- | ||
| Target Release: | --- | ||
| Hardware: | x86_64 | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | If docs needed, set a value | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | Type: | Bug | |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
|
Description
mhou
2023-07-14 07:49:10 UTC
Hi @mhou, n-handler-threads is not available on the newest openvswitch and kernel when using per-CPU dispatch mode. Openvswitch defaults to per-CPU dispatch in the latest kernel and OVS versions, and there is no way to change it. In effect n-handler-threads is only intended to be used in per-vport mode in older kernels. You can check which dispatch mode your system is running via `ovs-appctl dpif-netlink/dispatch-mode`. It is most likely in per-CPU dispatch mode which ignores n-handler-threads. The reason you have 31 Handlers threads is to balance the upcalls that could happen on all the CPUs. The way that is calculated is via you will have a minimum of what ever number of active CPUs, 29 in this case, plus an additional extra threads calculated via the next prime number from 29, which is 31 in this case I am working on ensuring that setting this parameter warns the user that making any changes has no effect and updating the documenttation if it's not clear enough that this setting is only intended to be used in per-vport mode and will not work in per-CPU mode Hello Michael Current mode actually is per-cpu mode on my test bed. # ovs-appctl dpif-netlink/dispatch-mode ovs-system: per-cpu dispatch mode The current ovs document didn't contain any section to describe what difference between per-CPU and per-vport. http://www.openvswitch.org/support/dist-docs/ovs-vswitchd.conf.db.5.txt other_config : n-handler-threads: optional string, containing an inte‐ ger, at least 1 Attempts to specify the number of threads for software datapaths to use for handling new flows. Some datapaths may choose to ig‐ nore this and it will be set to a sensible option for the data‐ path type. This configuration is per datapath. If you have more than one software datapath (e.g. some system bridges and some netdev bridges), then the total number of threads is n-handler-threads times the number of software datapaths. .... other_config : n-handler-threads optional string, containing an integer, at least 1 |