I've used the guide at https://maltechx.de/en/2021/03/opnsense-setup-traffic-shaping-and-reduce-bufferbloat/ as starting point with modification of weight for queues set at 50.
I've then duplicated these queues for "high priority" with a weight of 100 and created two additional rules for VOIP base (pic attached).
However status shows everything still using normal download queue. (pic attached)
I am guessing I've done something incorrect in rules but only addition I've added was VOIP IPs in Source/Destination which in my head are right way round for Upload/Download.
Can anyone offer any pointers?
My stupidity... missed sequence option - changed those so high priority first and appears to be working as expected now.
Your link to the shaper rules was pretty helpful to get mine sorted out ! ;) ;)
Thanks!
Quote from: via on October 11, 2024, 02:44:55 PM
I've then duplicated these queues for "high priority" with a weight of 100 and created two additional rules for VOIP base (pic attached).
Can anyone offer any pointers?
I'm sorry to disappoint but there's no such a thing of 'high priority queues' if you select fq_codel as scheduler, in your pipes. Fq_codel is all about sharing bandwidth. The priority field is simply ignored.
If you want to prioritize traffic using weights, you should use WFQ+ or QFQ (this latter is the best IMHO) as scheduler (remember to disable completely ECN from both queues and pipes). If you do that, you can start using the 'weight' field in your queues
Attached, an example of my queues where I have a number of different classes for Download and Upload (Platinum being the highest priority and Copper the lowest); the Platinum is for DNS, Ping and ACK, the rest of the classes is for my Work devices, PC and laptops, Media devices, iphone, tablets, IOT, CCTV and Lab test. Doing so, I'm making sure that the most important devices (ie Work) are never affected by whatever the other devices are doing (up to a certain point, as WFQ+ and QFQ will never 'starve' a queue for bandwidth in favour of another queue).
Cheers for that, was totally unaware. Never touched shaping before so went with fq_codel as that was what tutorial used lol
Will have a dig in further and try a different queue type. Can you mix and match? E.g. leaving fq_codel for normal traffic and setup different pipe and queues for VOIP? As there is a difference since using this for bufferbloat.
VOIP is very low bandwidth anyway and on 900 up/down but just want to make sure it is prioritised over everything else as that is my business phone line so want to make sure it runs as good as it can, nothing more off-putting than a bad quality line when trying to speak to a customer.
Otherwise happy for the rest to fight for the remaining bandwidth (well for now at least, may tweak it some more in future).
Quote from: via on October 17, 2024, 04:56:39 PM
Cheers for that, was totally unaware. Never touched shaping before so went with fq_codel as that was what tutorial used lol
Will have a dig in further and try a different queue type. Can you mix and match? E.g. leaving fq_codel for normal traffic and setup different pipe and queues for VOIP? As there is a difference since using this for bufferbloat.
VOIP is very low bandwidth anyway and on 900 up/down but just want to make sure it is prioritised over everything else as that is my business phone line so want to make sure it runs as good as it can, nothing more off-putting than a bad quality line when trying to speak to a customer.
Absolutely yes, you can mix and match in a number of ways... here's a couple if ideas:
Idea 1:
- You could define multiple queue considering various sizes of bandwidth, within your overall bandwidth allowance. For example, considering that you have a 500/500 Mbit link, you can carve 4 pipes of which:
- Example 1: 2 Pipes (Download and Upload) of, let's say 450 Mbits using QFQ as scheduler and a number of queues with weights that will divide the traffic to serve difference priorities (ie: work, games, media etc); the rules will point to those specific queues accordingly.
- Example 2: 2 Pipes (Download and Upload) of, let's 10 Mbit (for VoIP is quite a lot but... this is just an example :) ) using FQ_Codel as scheduler and 2 pipes (more or less like you did with your current configuration).
Regarding the 2 example above:
- Example 1, if you define VoIP with the highest weights (ie 90 or 100) the traffic will take precedence over the other queues, no matter what; QFQ is also very good with bufferbloat.
- Example2, the traffic for VoIP will get it's own, dedicated bandwidth (with Codel making the magic for bufferbloat); for your use case this is probably the best option as you will make sure that your VoIP will always have dedicated, 'clean' bandwidth, no matter what...
Idea 2:
- You could define your Pipes as 'normal', using QFQ as scheduler and FQ_Codel in your queues; this means, all the traffic for each queue will be 'sorted' by FQ_Codel and prioritized by QFQ. So you could have various queues (VoIP, Games, Work, Media etc etc) assign to them the relevant priority and FQ_Codel (or PIE, it's equally good). Just a note though; Codel or Pie will only soft the traffic out for each specific queue (so, let's say that you have 10 people talking to the phone using your VoIP system; Codel will make sure that each of those 10 people will get an amount of bandwidth with the target latency, no matter what). But... if you've defined an higher priority queue (ie Games get weights 75 and VoIP 30), the packets from Games will be processed and forwarded before the one in VoIP (as this is what QFQ is there for...).
Traffic Shaping is a very interesting matter, you can be very creative :)
Hope this helps, happy shaping :)