Comments (4)
If you run
ls /sys/class/net/INTERFACE/queues/
You should get an equivalent number of TX queues and CPU cores, or RX queues and CPU cores. RX and TX queues are almost always the same as the number of CPU cores unless there's a misconfiguration of the NIC. We just do the min() as a fail-safe in case of user misconfiguration of the NIC.
If we implement what you are proposing, wouldn't would we be limited to 4 queues on an 8 core system?
from libreqos.
I use the same command to get the number of TX queues for each interface. Here we have two issues:
- By running the command you mentioned, we get the number of TX queues for one interface. The issues is when we are not using onAStick mode, we have two interfaces. Therefore, the number of TX interfaces is twice as much as the number of cpuCount ( n TX queues for upstream and n TX queues for downstream bandwidth shaping). Therefore, if we want to compare do the min, we should get the minimum of number of TX queues for one interface and half of cpuCount
PS: Here I ignore the case when number of TX queues are not the same for each interface (Issue #375) - The other issue is that I used Veth for traffic shaping and I define the number of queues (using ethtool), so, the cpu count and number of TX queues are not the same.
from libreqos.
By running the command you mentioned, we get the number of TX queues for one interface.
Correct
The issues is when we are not using onAStick mode, we have two interfaces. Therefore, the number of TX interfaces is twice as much as the number of cpuCount ( n TX queues for upstream and n TX queues for downstream bandwidth shaping).
Ok right, but we are using ls /sys/class/net/INTERFACE/queues/
in LibreQoS.py. Each CPU core gets an RX and TX queue assigned by default. On an 8-core system, ls /sys/class/net/INTERFACE/queues/
will show 8 TX queues for interfaceA and 8 TX queues for interfaceB.
On line 479, queuesAvailable is calculated as queuesAvailable = min(InterfaceAQueuesAvailable, InterfaceBQueuesAvailable)
. So it's not the sum of TX queues, it's the minimum between the TX queues of each interface. I don't quite understand why we would use queuesAvailable = min( queuesAvailable , cpuCount//2)
.
The two interfaces being used would be identical SFP+ ports of a dual-port NIC, so rx/tx queues would be the same between them. We do not currently support configurations where someone wants to use two different model NICs, and that would probably not be easy to officially support in the long-term.
On a standard two-interface, one NIC config, if we were to use queuesAvailable = min( queuesAvailable , cpuCount//2)
- you would only be able to utilize half of the available CPU cores for queuing.
Please correct me if I am misunderstanding your proposal. Thanks. 👍
from libreqos.
I think you can support configurations when someone uses two different NIC models (Issue #375 and PR #377 ).
Also:
queuesAvailable = min(InterfaceAQueuesAvailable, InterfaceBQueuesAvailable)
queuesAvailable = min(queuesAvailable , CpuCount)
On a 8-core system, Interface A would have 8 TX queues and interface B would have 8 TX queues and the queuesAvailable=8. We have total of 16 TX queues that need to be managed but have 8 cores; which means every 2 TX queue would be managed by one CPU core. (In libreQoS.py, we would iterate 8 times for interface B queues and 8 times for interface A queues to generate tc command for each TX queue, in total 16 queues and 16 cpu cores!!)
But if use:
queuesAvailable = min(queuesAvailable , CpuCount//2)
queuesAvailable = 4
We would iterate 4 times for interface A and 4 times for interface B (in total, 8 queues and 8 cores )
PS: This line would be different when we use OnAStick mode or the number of queues per interface are different.
If it does not make sense, I would be happy to have a short meeting and talk about it.
from libreqos.
Related Issues (20)
- v1.5-beta: documentation lacks
- v1.5-beta: instalation build errors HOT 1
- v1.5-beta: version numbering not from VERSION_STRING HOT 3
- v1.5-beta (package from download link: libreqos_1.5.202406251802-1_amd64.deb for ubuntu22.04 - libpython3.10, build_dpkg.sh got some missed/broken check or no dependancy check, HOT 3
- v1.5-beta: lqosd: overflow when subtracting durations HOT 20
- v1.5-beta: improvement of lqos_scheduler startup needed
- v1.5-beta: too much debug information when running ./LibreQoS.py (without debug parameters) HOT 6
- v1.5-beta: reloading All QoS rules - don't drop packets for customers when doing partial reloading (c.d.) HOT 4
- v1.5-beta: setup assistant needs a little formating improvement
- v1.5-beta: problem with reloading HOT 42
- v1.5-beta: no 422 catcher register HOT 5
- v1.5-beta: problems with starting services in propper order/time/delay HOT 4
- Performance improvements during reloading
- "You must configure XDP bridging by editing the `/etc/lqos.conf` file on the server" Displayed in GUI HOT 1
- Splynx Integration works but Parent Node empty HOT 18
- How to update from 1.4 to 1.5 latest beta if installed using APT? HOT 2
- Splynx Integration issue: A single Client with 2 services is added twice with both IP addresses each time.
- Dashboard does not show behind Caddy reverse proxy HOT 3
- v1.5-beta2: web login problems after update
- Reloading interfaces network description HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from libreqos.