Shaper works at low bandwidth, but breaks at higher bandwidth

Started by tophattwaffle, March 01, 2023, 06:34:06 AM

Previous topic - Next topic
March 01, 2023, 06:34:06 AM Last Edit: March 01, 2023, 06:49:50 AM by tophattwaffle
I'm trying to setup upload traffic shaping in OPNsense, but am hitting a strange issue. The goal is to de-prioritize a network compared to another. I've setup the pipe, queues, and rules. I've setup an iperf3 server on a 3rd network to act as a test upload target.

When I have the pipe bandwidth at 50mbps, shaping works as expected. The low priority network gets ~8mbps and the high priority network gets ~40mbps as determined by the 2 queues I have with a weight of 1 for low, and 5 for high. When I set the bandwidth to 100mbps, my actual upload speed, the shaping dies and each host gets ~50mbps.

Bandwidth of 100mbps results in each host getting ~50mbps


Changing the bandwidth from 100 -> 50mbps and hitting apply, the rules start working immediately.



Pipe


Queues



Rules


The shaper code in the OS was built in a time where 100 mbit was fast and for all speeds past 100 mbit the timekeeping will be off and increasingly unreliable. You can't even shape over 5 gbps because the variable being held is not able to store this value anymore because it doesn't have enough bits.

I haven't heard that someone wanted to change that.


Cheers,
Franco
"AI has absolutely reduced the cost of creating technical debt." -- ChatGPT

Quote from: franco on March 01, 2023, 08:32:43 AM
The shaper code in the OS was built in a time where 100 mbit was fast and for all speeds past 100 mbit the timekeeping will be off and increasingly unreliable. You can't even shape over 5 gbps because the variable being held is not able to store this value anymore because it doesn't have enough bits.

I haven't heard that someone wanted to change that.


Cheers,
Franco

If I understand you correctly, this feature is basically not usable for faster links?

Yes, and shaping becomes less of a concern in these scenarios as well. At least that is what we are seeing with customers.


Cheers,
Franco
"AI has absolutely reduced the cost of creating technical debt." -- ChatGPT

Alright, thanks for the information. I'll have to just give up on this in my situation.