CAKE autorate-ingress turns speeds into molasses

I just got 7.1rc2 to try out CAKE without crashes. I also wanted to try out the autorate-ingress feature that lets me use CAKE without a bandwidth setting. However, it seems like this is actually slowing everything down to unacceptable levels. Bandwidth-heavy websites like YouTube and speedtest.net don’t even work that well on a RB4011 with minimal firewall rules. Is this a bug or something built into CAKE?

man-sch-cake

Automatic capacity estimation based on traffic arriving at this
qdisc. This is most likely to be useful with cellular links, which
tend to change quality randomly. A bandwidth parameter can be used
in conjunction to specify an initial estimate. The shaper will
periodically be set to a bandwidth slightly below the estimated rate.
This estimator cannot estimate the bandwidth of links downstream of
itself.

Not sure with estimator cannot estimate the bandwidth of links downstream of
itself
, maybe try set limit value with average speed.

I had a go with auto-ingress on rc1. My observation is that it slowly increases the allowed throughput until it hits the maximum throughput of the connection. My guess is that this is recognized by increasing latency. To avoid latency spikes they need to ramp up, if needs to be that slow is an other question …

I’ve never had luck with CAKE autorate-ingress even with OpenWrt, it’s better to just set a fixed max limit based on 85-90% of your real speeds.

Hej, the following config crashes my device after a short period. Can you reproduce it too?

/queue type
add cake-bandwidth=your-egress-bandwidth-here kind=cake name=cake-egress
add cake-autorate-ingress=yes cake-bandwidth=your-ingress-bandwidth-here kind=cake name=cake-ingress
/queue simple
add disabled=yes name=queue-foo queue=cake-ingress/cake-egress target=your-wan-interface-here

There has been a lot of work in the openwrt world to make the cake autorate feature work better over here.

https://forum.openwrt.org/t/cakes-autorate-ingress/108848/

It’s not ported to mikrotik yet, nor do I know how we would do that as yet. The math is shaping up, at least.

See also: http://forum.mikrotik.com/t/some-quick-comments-on-configuring-cake/152505/1

As someone with an LTE connection that can have bandwidth swings anywhere between 150 Mbps and 2 Mbps, I’d love to see autorate-ingress being worked on as well - I’m having this issue on RouterOS 7.16, it makes the internet connection essentially unusable.

Bump.

Still isn’t fixed in the latest build.

Confirmed, 7.19.4 still hasn't fixed it.

I’ve noticed that the autorate-ingress feature in CAKE still behaves unpredictably on RouterOS 7.20.1. While it does help reduce bufferbloat, it often causes unstable speeds — especially on LTE links where bandwidth fluctuates throughout the day.

The most reliable workaround I’ve found is to create two separate CAKE queue types: one for fast periods and one for slow. I then use scripts and the scheduler to switch between them based on predictable LTE performance patterns.

For example:

  • Weekdays before 17:00 — I use a cake-fast queue type with limits set to ~80–90% of my peak LTE speed.

  • Evenings and weekends — I switch to a cake-slow queue type with lower limits, since my LTE speeds typically drop by half or more.

This setup gives me stable latency and throughput without relying on autorate-ingress. It’s simple to maintain and adapts well to time-based congestion.

Would love to hear if others are using similar strategies or have found better ways to handle autorate on mobile links.

That's pretty cleaver, simple solution.

Another metric that might be useful to implement your "fast" and "slow" queue scheme is using /tool/netwatch on the LTE/5G and if latency on ICMP watch exceeds a certain level to switch to the slow queue (and reverse on "on-up")

1 Like

Doing QoS like that for LTE for a quite some time → https://forum.mikrotik.com/t/buyer-recommendations-for-noob-in-a-hurry/181540/28, just using different queue type - fq-codel, because cake was consuming too much cpu while this configuration was deployed on less cpu powered device and it was throttling bandwidth. Now when thinking, I can try now with cake to see how it goes since I meanwhile upgraded with new device…