What's new

CakeQOS CakeQOS-Merlin

  • 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!

In my super quick testing, reducing rtt below the time to the first hop (plus a little overhead) resulted in reduced throughput. It would seem based on this, that rtt functions something like an fine-tune setting.

if latency above rtt > throttle harder

I suspect that changing the value is only really useful in very specific cases to fully optimize and target a specific use (data center/high latency satellite), and won't have any real value for typical conditions.


You can also specify measurement method. Rather than "8000", you can use "8 ms".
I wanted to add this today after yesterday's testing. If it's too low you will indeed end up with stuttery mess - this will include if you're using a VPN connection on any client of course since there's an added length to travel to the server before the sites you want. "Accommodating for the worst connection". Those that aren't on a VPN on my end do benefit for metro on upload (even on wifi), however as I do use a VPN on some clients, I've bumped it to 25ms and will probably raise it a smidge higher still.

The setting definitely has a positive effect on performance if reducing latency is your goal and you can afford to lose some of your throughput for a very visible benefit, but I agree that there should be a limit and you shouldn't go so low. 100ms is the default, I just think that could be a bit tighter. Some people might have really shaky connections and should avoid this at all costs o_O
 
stuttery mess

Just for clarity, you mean the throughput? That is what I observed, the throughput would bounce up and down all over the place, whereas, using a reduced bandwidth shaper parameter will simply rate limit to the chosen value with a consistent throughput.

The setting definitely has a positive effect on performance if reducing latency is your goal and you can afford to lose some of your throughput for a very visible benefit,

Can you expand on this? My testing has been very simplified based on ping results to a close server. I suffer bufferbloat on my connection, but this is solved via bandwidth shaper parameters with a very minimal impact on throughput. I am not seeing any noticeable effect from rtt unless it is set incorrectly.
 
I wanted to add this today after yesterday's testing. If it's too low you will indeed end up with stuttery mess - this will include if you're using a VPN connection on any client of course since there's an added length to travel to the server before the sites you want. "Accommodating for the worst connection". Those that aren't on a VPN on my end do benefit for metro on upload (even on wifi), however as I do use a VPN on some clients, I've bumped it to 25ms and will probably raise it a smidge higher still.

The setting definitely has a positive effect on performance if reducing latency is your goal and you can afford to lose some of your throughput for a very visible benefit, but I agree that there should be a limit and you shouldn't go so low. 100ms is the default, I just think that could be a bit tighter. Some people might have really shaky connections and should avoid this at all costs o_O
Like I've said, I've set mine at metro (=10ms) because my measured (Jack Yaz's connmon - spdMerlin shows me just how well cake works and if things need tweaking) first hops are 7-8ms. back when I was using DDNS/Hurricane Electric tunnel, it was 28-32ms and jitter was 4-5x what it is now, so a 50ms setting would be fine, but a 30 would cause problems. the point of tweaking is to get the best connection out of what's available.
Unbound (not hopping out to look for an address is HUGE, plus avoiding the data collecting by google and cloudflare by going straight to Auth servers like the big boys) plus cake (keeping everything in line and on time) on native IPv6 makes my 50/10 DSL seem much faster and it's solid as Gibraltar.
 
Like I've said, I've set mine at metro (=10ms) because my measured (Jack Yaz's connmon - spdMerlin shows me just how well cake works and if things need tweaking) first hops are 7-8ms. back when I was using DDNS/Hurricane Electric tunnel, it was 28-32ms and jitter was 4-5x what it is now, so a 50ms setting would be fine, but a 30 would cause problems. the point of tweaking is to get the best connection out of what's available.
Unbound (not hopping out to look for an address is HUGE, plus avoiding the data collecting by google and cloudflare by going straight to Auth servers like the big boys) plus cake (keeping everything in line and on time) on native IPv6 makes my 50/10 DSL seem much faster and it's solid as Gibraltar.

@heysoundude I read your post and started using "metro" on my setup using Comcast. I got say "Metro" came to the rescure for me. Previously I would always get a "C" rating on bufferbloat test, but an"A" on quality & overall performance on my previous setup. I always thought that since I'm using a full-time VPN across my network this was probably normal and the reason that I could never accomplish an "A" bufferbloat rating.

I'm now using the setup below and please let me know if I need to make any adjustments but I'm now getting an "A" rating on all testing (Overall/Bufferbloat/Quality) thru the dls reports speedtest. Thanks again for this! My goal now is to get A+ bufferbloat rating haha.

Code:
[1]  --> Download Speed             | [65 Mbit]
[2]  --> Upload Speed               | [4 Mbit]
[3]  --> Queue Priority             | [diffserv4]
[4]  --> Extra Download Options     | [docsis metro]
[5]  --> Extra Upload Options       | [docsis ack-filter metro]
 
Can this be installed via amtm or does it need to be installed separately ?
 
@Daveo see the first few posts of this thread for installation.
 
@heysoundude I read your post and started using "metro" on my setup using Comcast. I got say "Metro" came to the rescure for me. Previously I would always get a "C" rating on bufferbloat test, but an"A" on quality & overall performance on my previous setup. I always thought that since I'm using a full-time VPN across my network this was probably normal and the reason that I could never accomplish an "A" bufferbloat rating.

I'm now using the setup below and please let me know if I need to make any adjustments but I'm now getting an "A" rating on all testing (Overall/Bufferbloat/Quality) thru the dls reports speedtest. Thanks again for this! My goal now is to get A+ bufferbloat rating haha.

Code:
[1]  --> Download Speed             | [65 Mbit]
[2]  --> Upload Speed               | [4 Mbit]
[3]  --> Queue Priority             | [diffserv4]
[4]  --> Extra Download Options     | [docsis metro]
[5]  --> Extra Upload Options       | [docsis ack-filter metro]

You're welcome. Now:
Looking at your settings, I (personally) wouldn't bother with speed limits.
Queue Priority- is that working for you? (All Packets Matter!)
Maybe Zeros for speed limits (your router can go faster than your connection; Comcast is limiting your speeds already, right?) and default besteffort Queue Priority (for the same reason) will get you the + you're after.
Try it and get back to us, would you please?
 
I have been going back and forth between Cake-Qos and FlexQoS. Since my household is fairly simple in terms of WAN access (no kids home playing games, both my wife and I are retired so no Skype/Teams), I decided to try Cake-QoS again, especially after reading some of the settings/research @Linux_Chemist has been using.

I'm on a Spectrum 100/10 cable modem that spdMerlin consistently shows 110/11. I also did some ping tests today and settled on 30 msec.
This is an AX88U running 384.19.

My settings:

Code:
## Installer ##
dlspeed="110"
upspeed="11"
queueprio="diffserv4"
optionsdl="docsis nowash rtt 30000"
optionsup="docsis ack-filter rtt 30000"

Very nice. I have never been able to get an A+ across the board. With the above setup, I am getting consistent A+
1600274910861.png


Thanks folks!
 
I could use some help as a relative noob to this kind of thing. I managed to install CakeQOS on my RT-AC86U router, running on Merlin 384.18. I have Cox HSI with a Cisco DPC3010 DOCSIS 3.0 8x4 modem. Advertised speed is 150 down and 10 up. I normally get that or a little better when I have tested in the past.
Before installing Cake, I was mostly getting B's and C's for my bufferbloat on dslreports. Afterwards, I was getting mostly C's and D's. So I must need to configure it a little better. I have reviewed the guide at https://www.man7.org/linux/man-pages/man8/tc-cake.8.html, but I don't know how to decide what settings I should change for my situation. I did try the docsis and ack-filter options, but those actually made it worse.

Could a generous and patient soul out there help me out?

Also, here are the initial statuses after installation and starting it up (before I tried the docsis and ack-filter options):
Code:
CakeQOS-Merlin: > Download Status:
qdisc cake 8003: dev ifb9eth0 root refcnt 2 bandwidth 150Mbit besteffort triple-isolate nat wash ingress no-ack-filter split-gso rtt 100.0ms raw overhead 0 no-sce

CakeQOS-Merlin: > Upload Status:
qdisc cake 8001: dev eth0 root refcnt 2 bandwidth 10Mbit besteffort triple-isolate nat nowash no-ack-filter split-gso rtt 100.0ms raw overhead 0 no-sce
 
Thanks for sharing this! I had been using a ubiquiti edgerouter x and it's smart queue feature (htb + fq_codel) behind an asus ac86u, to manage the queue and prevent clients from hogging all the bandwidth, while the asus was handling openvpn. But thanks to cake-qos, I was able to retire the edgerouter and move queue management to the asus as well. Thanks to cake's performance, I'm also now able to use more of my ISP's bandwidth (130M/15M), since the old edgerouter and its QoS performance was CPU capped at around 80M/10M.

I've installed cake on 2 AC86U routers so far. But on one of my routers, i'm seeing some sporadic qos errors in the system log:

[COLOR=rgb(184, 49, 47)]Sep 15 04:44:02 kernel: ERR[update_qos_data_by_mac:3585] Failed to find udb entry by skb src-MAC! Sep 15 04:44:09 kernel: ERR[update_qos_data_by_mac:3585] Failed to find udb entry by skb src-MAC! Sep 15 04:44:15 kernel: ERR[update_qos_data_by_mac:3585] Failed to find udb entry by skb src-MAC! Sep 15 05:04:29 kernel: ERR[update_qos_data_by_mac:3585] Failed to find udb entry by skb src-MAC![/COLOR]

They're pretty random. There were about 50 of them yesterday in the logs. When it happens, there are usually a few back to back in the log. I'm not hearing any complaints about connectivity (router is feeding some access points for hotspot connectivity at a small biz, under 50 clients, ~30 on average), so maybe this is safe to ignore.

Any ideas what this error means and if or how to resolve it?

Here's the cake config if needed:
[1] --> Download Speed | [117 Mbit]
[2] --> Upload Speed | [13.5 Mbit]
[3] --> Queue Priority | [besteffort]
[4] --> Extra Download Options | [conservative]
[5] --> Extra Upload Options | [conservative]

Here's one hypothesis, which I hope to test this weekend. The router throwing the error is using the MAC Clone feature, and given the error code mentions "src-MAC", maybe this has something to do with it? The router is at an offsite location, but I plan to visit this weekend and see if the ISP can update the mac on their end, so I can turn the mac cloning feature off. The device's MAC that the router cloned is still connected to LAN, so maybe its tripping something up in that the QoS function referenced in the logs.

Any one know if there is way to turn up the logging to see what mac address(es) are triggering the error?

Thanks in advance for the help!
 
I could use some help as a relative noob to this kind of thing. I managed to install CakeQOS on my RT-AC86U router, running on Merlin 384.18. I have Cox HSI with a Cisco DPC3010 DOCSIS 3.0 8x4 modem. Advertised speed is 150 down and 10 up. I normally get that or a little better when I have tested in the past.
Before installing Cake, I was mostly getting B's and C's for my bufferbloat on dslreports. Afterwards, I was getting mostly C's and D's. So I must need to configure it a little better. I have reviewed the guide at https://www.man7.org/linux/man-pages/man8/tc-cake.8.html, but I don't know how to decide what settings I should change for my situation. I did try the docsis and ack-filter options, but those actually made it worse.

Could a generous and patient soul out there help me out?

Also, here are the initial statuses after installation and starting it up (before I tried the docsis and ack-filter options):
Code:
CakeQOS-Merlin: > Download Status:
qdisc cake 8003: dev ifb9eth0 root refcnt 2 bandwidth 150Mbit besteffort triple-isolate nat wash ingress no-ack-filter split-gso rtt 100.0ms raw overhead 0 no-sce

CakeQOS-Merlin: > Upload Status:
qdisc cake 8001: dev eth0 root refcnt 2 bandwidth 10Mbit besteffort triple-isolate nat nowash no-ack-filter split-gso rtt 100.0ms raw overhead 0 no-sce

I have a similar setup, cable/docsis 100/10. After using @Linux_Chemist settings and doing some ping (rtt) measurements, I am getting all A's (and some A+!)

I also have installed spdMerlin. I have gotten 117Mbit down, 11Mbit up for months very consistent.
Measure a variety of ping times and there is a utility called betterspeedtst.sh that was in the /jffs/addons/util directory. I don't recall how it got there!!!!
If you don't have it installed on your router, here is the script:


In any case, note that the default rtt is 100 mSec. I would bet your average is much lower.
My testing showed an average of 30 mSec. I believe that setting the more correct rtt made the biggest improvement in my case.

Here are my settings:

download speed: 110
upload speed: 11
Queue Priority: diffserv4
Download options: docsis nowash rtt 30000
Upload options: docsis ack-filter rtt 30000

Try those as a starting point.
Good luck
 
Just for clarity, you mean the throughput? That is what I observed, the throughput would bounce up and down all over the place, whereas, using a reduced bandwidth shaper parameter will simply rate limit to the chosen value with a consistent throughput.



Can you expand on this? My testing has been very simplified based on ping results to a close server. I suffer bufferbloat on my connection, but this is solved via bandwidth shaper parameters with a very minimal impact on throughput. I am not seeing any noticeable effect from rtt unless it is set incorrectly.

Throughput yes, and it seems to play a noticeable affect when browsing on a vpn in particular for downloading big videos (e.g. twitch). Set the rtt incorrectly (too low) and it feels like requests get delayed or dropped altogether and it leads to an absolute stuttery mess. To tell you the truth, without quantifying it, the change is more significant on 100ms vs not-100 ms. I can see pages loading faster but that's quantifiable and I've not done the legwork to measure it just yet so take it with much sodium chloride. I'd like to see if others notice it too or could quantify it before I get round to it.


rtt 30000 is equivalent to regional btw if that's easier to type :p

Having cake-qos is making a great impact to internet usage, I'm grateful it's been integrated for consumption.
 
In any case, note that the default rtt is 100 mSec. I would bet your average is much lower.
My testing showed an average of 30 mSec. I believe that setting the more correct rtt made the biggest improvement in my case.

Here are my settings:

download speed: 110
upload speed: 11
Queue Priority: diffserv4
Download options: docsis nowash rtt 30000
Upload options: docsis ack-filter rtt 30000

Try those as a starting point.
Good luck

Yes, my average ping is right around 30 mSec. I'll give that a try when I get a chance in the next couple of days.
I'm curious, though, what will happen if it is set that low, but then I have a connection that has much slower rtt? For example, I play a game that depends on peer-to-peer connections, and sometimes I play with a guy that is literally on the opposite side of the planet from me. What unintended side-effects might I experience in that situation if I set my rtt to 30000?
@Linux_Chemist you might have some ideas on this, too, based on your previous post.
 
Yes, my average ping is right around 30 mSec. I'll give that a try when I get a chance in the next couple of days.
I'm curious, though, what will happen if it is set that low, but then I have a connection that has much slower rtt? For example, I play a game that depends on peer-to-peer connections, and sometimes I play with a guy that is literally on the opposite side of the planet from me. What unintended side-effects might I experience in that situation if I set my rtt to 30000?
@Linux_Chemist you might have some ideas on this, too, based on your previous post.
Err on a larger number to be safe. If it has the potential to go up to 40, save yourself the aggravation and set it to 40ms for a worstcase scenario on download. Upload should be lower but this is in a non-vpn scenario.
Personally, if not experimenting, I would say set it and forget it at 50 or 60 (be explicit with ms or 50000/60000 otherwise it will think you mean 50 nanoseconds!) for both and don't worry about it. It's just trying to make sure the connection is doing a fraction of a second less waiting - we are talking 1/10 of a second default vs 1/20 lol

Some people will have really poor internet connections (house in the middle of nowhere or satellite connection only) and the default 100ms will actually be awful for them already - they might need that up to 200 or 300ms+.
 
Last edited by a moderator:
Err on a larger number to be safe. If it has the potential to go up to 40, save yourself the aggravation and set it to 40ms for a worstcase scenario on download. Upload should be lower but this is in a non-vpn scenario.
Personally, if not experimenting, I would say set it and forget it at 50 or 60 (be explicit with ms or 50000/60000 otherwise it will think you mean 50 nanoseconds!) for both and don't worry about it. It's just trying to make sure the connection is doing a fraction of a second less waiting - we are talking 1/10 of a second default vs 1/20 lol

Some people will have really poor internet connections (house in the middle of nowhere or satellite connection only) and the default 100ms will actually be awful for them already - they might need that up to 200 or 300ms+.
I've printed out cake's man page - it's often easier for me to absorb what I read off paper.
The 2nd paragraph of the description is most notable:

All settings are optional; the default settings are chosen to be
sensible in most common deployments. Most people will only need to
set the bandwidth parameter to get useful results, but reading the
Overhead Compensation and Round Trip Time sections is strongly
encouraged.

the BUT is what most people miss.
Further, the Failsafe Overhead keywords wouldn't be terrible to take particular note of either:

These two keywords are provided for quick-and-dirty setup. Use them
if you can't be bothered to read the rest of this section.

raw (default)
Turns off all overhead compensation in CAKE. The packet size
reported by Linux will be used directly.

Other overhead keywords may be added after "raw". The effect of
this is to make the overhead compensation operate relative to the
reported packet size, not the underlying IP packet size.


conservative
Compensates for more overhead than is likely to occur on any
widely-deployed link technology.
Equivalent to overhead 48 atm.

SO, to be safe, put raw in first BEFORE any ADSL/VDSL/DOCSIS modifiers - in case you're human. cake has your back.

Also, I suspect you'll want to choose nonat for flow isolation if you're IPv6 to further lighten/speed cake, also first before dual-xxxhost etc...I'll test that later and get back to y'all
 
Last edited:
Hey everyone . I'm new here and I'm stuck on this entware that is mentioned....is there a script for this cause i have the ax88u and when running cake it tells me entware is not on my system...any help would be appreciated!! I have looked and still don't see anything regarding installation of it.
 
Hey everyone . I'm new here and I'm stuck on this entware that is mentioned....is there a script for this cause i have the ax88u and when running cake it tells me entware is not on my system...any help would be appreciated!! I have looked and still don't see anything regarding installation of it.

Best thing to do is install amtm.
 
You don't need to install amtm if you're running RMerlin firmware 384.15_0 or later (it is built into the firmware).

The following guide may be helpful.

 
Hey everyone . I'm new here and I'm stuck on this entware that is mentioned....is there a script for this cause i have the ax88u and when running cake it tells me entware is not on my system...any help would be appreciated!! I have looked and still don't see anything regarding installation of it.
this tells me you can access the command line. Have you tried issuing the command amtm?
enjoy... ;-D
 
Probably a dumb question but I can't seem to find an answer after searching these posts or the install instructions, but do I need to enable QOS inside the router before I install CAKE?
 

Latest threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

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