What's new

CakeQOS CakeQoS-Merlin v2.0.0

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

For some reason I was butt backwards before with thinking eth0 was download. Anyway....

To specify the destination port, try with u16 at 2 instead of u16 at 0, still on ifb4eth0.

Still seeing all of the download going to besteffort tin.

Code:
tc filter add dev ifb4eth0 parent 800a: protocol ip prio 30 basic match "cmp(u16 at 2 layer transport gt 63330) and cmp(u16 at 2 layer transport lt 63339)" action skbedit priority 800a:1
 
For some reason I was butt backwards before with thinking eth0 was download. Anyway....



Still seeing all of the download going to besteffort tin.

Code:
tc filter add dev ifb4eth0 parent 800a: protocol ip prio 30 basic match "cmp(u16 at 2 layer transport gt 63330) and cmp(u16 at 2 layer transport lt 63339)" action skbedit priority 800a:1
Are you taking into account the lower and upper bounds of the port range, since these are less than and greater than, and not less than or equal to, etc? I’m not confident this filter would work in the first place, but let’s make sure it’s accurate.
Code:
tc -s filter show dev ifb4eth0
 
Are you taking into account the lower and upper bounds of the port range[/CODE]

Yes sir, already been through that mistake.

Code:
 tc -s filter show dev ifb4eth0
filter parent 800a: protocol ip pref 30 basic
filter parent 800a: protocol ip pref 30 basic handle 0x1
  cmp(u16 at 2 layer 2 gt 63330)
  AND cmp(u16 at 2 layer 2 lt 63339)

        action order 1: skbedit  priority 800a:1 pipe
         index 5 ref 1 bind 1 installed 1167 sec used 1167 sec firstused 1889786921 sec
        Action statistics:
        Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0)
        backlog 0b 0p requeues 0
 
Do you happen to run spdMerlin, which would temporarily disable QoS during a speedtest?
spdMerlin is installed: thanks for pointing to this.
 
There's a 2.1 beta on the develop branch that includes the initial workings of iptables rules for upload traffic. It's disabled by default because not everyone will need or want to use them.

1622508127075.png


Once you click Yes, the rules section will display and you can add either some "well-known" rules that are pre-defined in the dropdown, or create a new rule from scratch.

1622508259247.png


No rules are active by default, so the table will be empty the first time you enable the upload classification.

The Category dropdown contains generic descriptions for some initial types of traffic you may want to re-tin. The options and their assigned DSCP values are:
  • Bulk: CS1
  • Streaming: AF31
  • Voice: EF
  • Conferencing: AF41
  • Gaming: CS4
If you're interested in testing this feature, you can install the develop branch version of the script, which will show as v2.1.0 in the GUI.
Bash:
mkdir -p /jffs/addons/cake-qos && /usr/sbin/curl -s "https://raw.githubusercontent.com/ttgapers/cakeqos-merlin/develop/cake-qos.sh" -o "/jffs/addons/cake-qos/cake-qos" && chmod 755 /jffs/addons/cake-qos/cake-qos && sh /jffs/addons/cake-qos/cake-qos install
 
There's a 2.1 beta on the develop branch that includes the initial workings of iptables rules for upload traffic. It's disabled by default because not everyone will need or want to use them.

View attachment 34154

Once you click Yes, the rules section will display and you can add either some "well-known" rules that are pre-defined in the dropdown, or create a new rule from scratch.

View attachment 34155

No rules are active by default, so the table will be empty the first time you enable the upload classification.

The Category dropdown contains generic descriptions for some initial types of traffic you may want to re-tin. The options and their assigned DSCP values are:
  • Bulk: CS1
  • Streaming: AF31
  • Voice: EF
  • Conferencing: AF41
  • Gaming: CS4
If you're interested in testing this feature, you can install the develop branch version of the script, which will show as v2.1.0 in the GUI.
Bash:
mkdir -p /jffs/addons/cake-qos && /usr/sbin/curl -s "https://raw.githubusercontent.com/ttgapers/cakeqos-merlin/develop/cake-qos.sh" -o "/jffs/addons/cake-qos/cake-qos" && chmod 755 /jffs/addons/cake-qos/cake-qos && sh /jffs/addons/cake-qos/cake-qos install
Awesome work @dave14305

I'm testing it out now....

If I setup the pre-defined rules for Zoom/Teams within the CAKE GUI using beta v2.1.0, would I still need to use the /jffs/scripts/qos-start script with these values inside as well, or it's no longer required:

Code:
#!/bin/sh

iptables -t mangle -D POSTROUTING -o eth0 -p udp -m multiport --dports 3478:3481 -j DSCP --set-dscp-class EF 2>/dev/null
iptables -t mangle -A POSTROUTING -o eth0 -p udp -m multiport --dports 3478:3481 -j DSCP --set-dscp-class EF
iptables -t mangle -D POSTROUTING -o eth0 -p udp -m multiport --dports 8801:8810 -j DSCP --set-dscp-class EF 2>/dev/null
iptables -t mangle -A POSTROUTING -o eth0 -p udp -m multiport --dports 8801:8810 -j DSCP --set-dscp-class EF

One last question, does it matter which rule is created 1st? For instance, should my gaming rule be last similiar to when using Flex or it does not matter which order they're created in? Thanks!
 
Last edited:
One last question, does it matter which rule is created 1st? For instance, should my gaming rule be last similiar to when using Flex or it does not matter which order they're created in? Thanks!
Everything within a category would be treated equally by cake since it all goes into a specific tin.

You can see what DCSCP marks get moved into which tins on the man page under "Priority Queue Parameters". (It depends which "diffservx" you use.

As far as I can tell, the only difference between diffserv3 and diffserv4 with this scheme is that gaming will be lumped into besteffort with the streaming and conferencing in diffserv3, whereas on diffserv4, gaming will be grouped as high priority with voice, with streaming and conferencing given a slight edge over besteffort.

I'd be inclined to use diffserv4 if the default DSCP to tin mapping is in play is how it is all working. (otherwise gaming, streaming and conferencing categories don't really do much.
 
Last edited:
If I setup the pre-defined rules for Zoom/Teams within the CAKE GUI using beta v2.1.0, would I still need to use the /jffs/scripts/qos-start script with these values inside as well, or it's no longer required:
They would no longer be needed.
One last question, does it matter which rule is created 1st? For instance, should my gaming rule be last similiar to when using Flex or it does not matter which order they're created in?
It’s the same situation as FlexQoS where the last matching rule will determine the final DSCP value if more than one rule matches.
As far as I can tell, the only difference between diffserv3 and diffserv4 with this scheme is that gaming will be lumped into besteffort with the streaming and conferencing in diffserv3, whereas on diffserv4, gaming will be grouped as high priority with voice, with streaming and conferencing given a slight edge over besteffort.

I'd be inclined to use diffserv4 if the default DSCP to tin mapping is in play is how it is all working. (otherwise gaming, streaming and conferencing categories don't really do much.
I took the initial DSCP values from the cake source code as a starting point.
If using diffserv3, one can always override the Category in the rule to be Voice instead of Conferencing or Gaming. I just needed a starting point.
 
I know the ui does not allow changing downloads to a tin. But could I send all download traffic from one specific ip to a specific tin?
 
I know the ui does not allow changing downloads to a tin. But could I send all download traffic from one specific ip to a specific tin?
If it’s a specific external IP, it should be possible with a tc filter. If it’s an internal destination IP on the LAN, I’m guessing it isn’t possible because the traffic hasn’t been de-NATted at that point.
 
Does the max 250Mbps rule still apply for the AX88u ? I’m getting a upgrade soon to 300Mbps and was just curious.
 
Yes. All the compatible routers have the same single-core CPU speed and thus the same limitation.
What side effect can I expect from the extra 50Mbps over limit ?
 
Does the max 250Mbps rule still apply for the AX88u ? I’m getting a upgrade soon to 300Mbps and was just curious.

Not really a rule - but guidance. As mentioned others have used QoS with higher speeds than 250....

Cheers :) I am wanting an connection upgrade here, but alas there aren't any options!
 
I started using cake a few months ago and it has worked great. Just today I noticed some weird speed drops. I initially thought my cable company dropped me down a speed tier since I just renegotiated our rate but when I turned off cake my speeds were as expected. I ran speed tests on 4 different devices and they all came in at 160/10. I'm also the only person in the house. Anybody seeing this? Details about my connection and setup below.

AX88U with AX58U setup as an AP. Internet 250/15. Without QOS I can pull close to 300 down. I have tried turning off QOS while I'm getting these slow speeds and download shoots right back up to 300.

Cake set at 260/15 with DOCSIS overhead. It usually speed tests in the 240-250 range with around 14 up.
CakeQOS-Merlin all default with Filter Dup ACK's on upload only on.
 
They would no longer be needed.

It’s the same situation as FlexQoS where the last matching rule will determine the final DSCP value if more than one rule matches.

I took the initial DSCP values from the cake source code as a starting point.
If using diffserv3, one can always override the Category in the rule to be Voice instead of Conferencing or Gaming. I just needed a starting point.
There's a 2.1 beta on the develop branch that includes the initial workings of iptables rules for upload traffic. It's disabled by default because not everyone will need or want to use them.

View attachment 34154

Once you click Yes, the rules section will display and you can add either some "well-known" rules that are pre-defined in the dropdown, or create a new rule from scratch.

View attachment 34155

No rules are active by default, so the table will be empty the first time you enable the upload classification.

The Category dropdown contains generic descriptions for some initial types of traffic you may want to re-tin. The options and their assigned DSCP values are:
  • Bulk: CS1
  • Streaming: AF31
  • Voice: EF
  • Conferencing: AF41
  • Gaming: CS4
If you're interested in testing this feature, you can install the develop branch version of the script, which will show as v2.1.0 in the GUI.
Bash:
mkdir -p /jffs/addons/cake-qos && /usr/sbin/curl -s "https://raw.githubusercontent.com/ttgapers/cakeqos-merlin/develop/cake-qos.sh" -o "/jffs/addons/cake-qos/cake-qos" && chmod 755 /jffs/addons/cake-qos/cake-qos && sh /jffs/addons/cake-qos/cake-qos install
Thank you for this!! Installed on AX-86U running 386.2_4.

Can I inspect the iptables from the command line to see the rules? I tried this command (but do not see the static IP for a VoIP gateway that I assigned as a Local IP to Voice category):
INI:
iptables --list
 
Thank you for this!! Installed on AX-86U running 386.2_4.

Can I inspect the iptables from the command line to see the rules? I tried this command (but do not see the static IP for a VoIP gateway that I assigned as a Local IP to Voice category):
INI:
iptables --list
Run:
Code:
iptables -t mangle -nvL CakeQOS-Merlin
 
Run:
Code:
iptables -t mangle -nvL CakeQOS-Merlin
Thanks - that works perfectly.

UPDATE: just realized that the default priority queue diffserv3 doesn't include the category "conferencing" which is default category for the given well known iptables rules - so I changed them all to "voice" category. All seems to work fine.
 
Last edited:

Similar threads

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top