Help me traffic shape (HFSC vs PRIQ)
PhantomsWay last edited by
I've been using schedules to limit bandwidth for the entire network during times when live streams happen. The problem is that there is unused bandwidth. I am looking at traffic shaping to resolve this. Here is my proposal, please tell me what kind of corrections I can do.
I want to understand traffic shaping. DO NOT TELL ME TO USE THE WIZARD. PERIOD. I AM SICK of seeing the wizard made rules all over the internet. I have used them and still experience drops because it configured based on bandwidth percentage which does not work in my situation. I want to make everything from scratch and I need to be able to control everything with bit per second in the queue settings. I've spent a lot of time trying to learning the service curve concept for hsfc to decouple delay and want to manually set things up for the sake of experience and knowledge.
My upload speed: 12 megabits per second
I need to prioritize RTMP (1935/TCP) and guarantee no dropped packet at all. ZERO*. I am experiencing dropped packets and it's disrupting my service. I understand it's TCP and is designed to handle that, but I would rather have dropped packets in lower priority traffic than the RTMP service.
My understanding is that I will need to prioritize RTMP and ACKs. I don't care about the rest and once I understand how this works then I will modify and add custom services as needed.
Starting off with PRIQ. Here are the steps I took, let me know where I went wrong:
1. Went to traffic shape page
2. Clicked on WAN interface, set bandwidth to 11500000 bits (11.5 megabits), clicked save and apply.
3. Created a new queue under that WAN and named it ACK, set priority to 7 (should I do this? Guarantee ACKs top priority?)
4. Created a new queue under WAN and named it RTMP, set priority to 6.
5. Created a new queue named Upload and made it the default queue with the default priority of 1 (left room in between to add other services if needed).
6. Went to the firewall, floating rules and made the following rules in the following order (top to bottom in the firewall list):
7. Name: Upload, Action: Match, Interface: WAN, Direction: Out, Any to Any, ACKqueue: ACK, Queue: Upload
8. Name: RTMP, Action: Match, Interface: WAN, Direction: Out, Any to TCP 1935, ACKqueue: ACK, Queue: RTMP
Here are my observations in the queues status
-Traffic in ACKs, no drops and nothing lined up in the queue, there is a little bit of traffic
-RTMP traffic, a lot of drops, sometimes some lined up in the queue
-upload queue has the same story, but there are more drops in the RTMP queue which is what I am trying to avoid
Where did I go wrong with my configuration?
I pretty much did the same setup except instead of priority values, I used the HFSC realtime bandwidth for ACKs (first) and RTMP (second).
Observation: The bandwidth used does not match up in the queues but there are no packet drops.
What am I doing wrong?
PhantomsWay last edited by
bbrendon last edited by
Not what you're asking for but two tips.
1. I would guess that about 80% of the documentation on traffic shaping you read online is full of miss-information. I've watched many youtube videos and read many blogs and forum posts that are sprinkled with incorrect statements. Check the author's credibility before you take their information as fact.
2. Use PRIQ if you can. It is much easier to deal with if it fits your requirements. (or if you can make it fit your requirements).
Chrismallia last edited by
Try limiters with fq_codel in 2.4
Do as Johnpoz did in post 121, it will give the full bandwidth if the network is quiet but will split when needed + reducing bufferbloat