Hmm yes this makes no sense:
Looks like cake is not actually set up on the interfaces?
Output from tc qdisc ls
?
Hmm yes this makes no sense:
Looks like cake is not actually set up on the interfaces?
Output from tc qdisc ls
?
qdisc noqueue 0: dev lo root refcnt 2
qdisc mq 0: dev eth0 root
qdisc fq_codel 0: dev eth0 parent :5 limit 10240p flows 1024 quantum 1514 target 5ms interval 100ms memory_limit 4Mb ecn drop_batch 64
qdisc fq_codel 0: dev eth0 parent :4 limit 10240p flows 1024 quantum 1514 target 5ms interval 100ms memory_limit 4Mb ecn drop_batch 64
qdisc fq_codel 0: dev eth0 parent :3 limit 10240p flows 1024 quantum 1514 target 5ms interval 100ms memory_limit 4Mb ecn drop_batch 64
qdisc fq_codel 0: dev eth0 parent :2 limit 10240p flows 1024 quantum 1514 target 5ms interval 100ms memory_limit 4Mb ecn drop_batch 64
qdisc fq_codel 0: dev eth0 parent :1 limit 10240p flows 1024 quantum 1514 target 5ms interval 100ms memory_limit 4Mb ecn drop_batch 64
qdisc cake 8481: dev eth1 root refcnt 2 bandwidth 400Mbit besteffort triple-isolate nonat nowash no-ack-filter split-gso rtt 100ms noatm overhead 54 mpu 84
qdisc ingress ffff: dev eth1 parent ffff:fff1 ----------------
qdisc fq_codel 0: dev phy0-ap0 root refcnt 2 limit 10240p flows 1024 quantum 1514 target 5ms interval 100ms memory_limit 4Mb ecn drop_batch 64
qdisc noqueue 0: dev br-lan root refcnt 2
qdisc noqueue 0: dev map-wan root refcnt 2
qdisc cake 8482: dev ifb4eth1 root refcnt 2 bandwidth 400Mbit besteffort triple-isolate nonat wash no-ack-filter split-gso rtt 100ms noatm overhead 54 mpu 84
The wan device appears to have cake~
I am using a map-e tunnel provided by my isp... but should be routed through the eth1 device~
just to be safe I've changed all lan- eth0 devices with the exception of my wireless ap to use cake~ with same bandwidth +settings to my wan
qdisc cake 84d8: dev eth0 root refcnt 6 bandwidth 400Mbit besteffort triple-isolate nonat wash no-ack-filter split-gso rtt 5ms noatm overhead 38 mpu 84
qdisc cake 8562: dev eth1 root refcnt 2 bandwidth 400Mbit besteffort triple-isolate nonat nowash no-ack-filter split-gso rtt 100ms noatm overhead 54 mpu 84
qdisc ingress ffff: dev eth1 parent ffff:fff1 ----------------
qdisc cake 84dd: dev phy0-ap0 root refcnt 2 bandwidth 40Mbit besteffort triple-isolate nonat wash no-ack-filter split-gso rtt 5ms raw overhead 0
qdisc cake 8517: dev br-lan root refcnt 2 bandwidth 400Mbit diffserv3 triple-isolate nonat nowash no-ack-filter split-gso rtt 100ms noatm overhead 38 mpu 84
qdisc cake 84e2: dev map-wan root refcnt 2 bandwidth 400Mbit besteffort triple-isolate nonat wash no-ack-filter split-gso rtt 5ms noatm overhead 38 mpu 84
qdisc cake 8563: dev ifb4eth1 root refcnt 2 bandwidth 400Mbit besteffort triple-isolate nonat wash no-ack-filter split-gso rtt 100ms noatm overhead 54 mpu 84
So im not entirely sure what exactly is happening, but my changes to the config.primary.sh wont commit after a reboot, or upon stoping and starting the service.
it's not until I install the autorate again does it start to temporarily work for me, im not sure if its due to my system or something else.
it will also not update the cake-autorate SUMMARY changes after a while in the logs and just have it reading the base rates set to the line~.
There may be a conflicting app i've installed/missing on my openwrt~ if there is an app that i shouldn't install along with the autorate please let me know
could someone make a video on how to set this up?
i have a 1200 down and 40 up but i get 850down when i run a speed test. im starting to understand openwrt more and more coming from a normal house hold router
for the min download i would leave it as is and same for base right? but for the max download id set it to what i set in the sqm so it would be 850mb down plus the 90% = 765mb down. same gos for the upload 40mb plus the 90% = 36mb up and would set that to max_ul to 36mb? or am i missing somthing?
It might be Faster Through reading, I'll try to summarize it~
copy the lines below, and right click to paste inside of shell~
wget -O /tmp/cake-autorate_setup.sh https://raw.githubusercontent.com/lynxthecat/cake-autorate/master/setup.sh
sh /tmp/cake-autorate_setup.sh
oh and type in
service cake-autorate enable
service cake-autorate start
and then~~ fall in love with lynx
If using terminal / shell/cmd prompt is too difficult, it may be a bit of a skill issue but worth the effort( i still dont know what im doing)
mmmm the logs dont appear to be updating but as of right now my... rates dont seem to be recovering~
Mmmmh, 1200/40 = 30:1
-> that is pretty close to the ~40:1 ratio of TCP Reno ACK to data volume... By all means that is not a healthy asymmetric ratio... (and, respectfully, either a sign of incompetence or ignorance on your ISP's part). So I fully agree in shaping the download down to something saner << 1 Gbps...
For Upload, one can typically shape pretty close to the actual limit. Since cake interprets the shaper rates as gross rates (out of necessity) but speed/capacity tests report net rates, for the upload ne can typically start with just plugging the speed test values directly into cake and just do a bufferbloat test to confirm this is good enough... (and if desired one can then still iteratively try to see whether one can increase the shaper rate even further). That said, taking 90% of the achieved speed test result should also work well from a latency under load perspective.
Do yourself a favour and first have a look at these scripts (e.g. by looking at the code in github with your browser). In this instance I think you will find code that does what it claims to do with no evil lurking inside, but whenever you load and execute code on your firewall/router make doubly sure to convince yourself the code is benign, your home network's security depends on its administrator being careful.
im using notpad to edit the files with filezilla.
how did you decide your values in the dl shaper min,base and max and same for your upload?
im on 1200 down and 40 up but when i speed test i get about 850 down so trying to figure out what to set them to.
also how did you get the stuff in your overrides? i dont see that other then
### See defaults.sh for additional configuration options
### that can be set in this configuration file to override the defaults.
### Place any such overrides below this line.
or did you have to add that your self?
here is a test result before sqm
and then here is the test with both 90% rule down and up
im doing this test in 8Am where everyone is asleep but these test aren't the same threw out the day.
from reading threw the forums and trying to understand more i have Link layer setup like this. im with comcast/Xfinity
so i feel like auto-rate could help me out threw out the day with 30-40 devices connected in my house threw out the day
edit:
this test was done 5 mins after and as you can see the jitter starts increase in the downloads
also i just want to note that the hardware im using for testing openwrt is a Minisforum UM250 with the cpu being a Ryzen 5 Pro 2500U once im done figuring out openwrt i will switch to my main one being a HUNSN Micro Firewall Appliance with a cpu Intel N5105 with a 4 x 2.5GbE I226 ports
edit: 15 mins after and here is the test again
So here is the rub, under load autorate will try to find the highest rate <= the configured max. rate at which the variable part of the observed latency stays below your configured threshold. The max rate is more an optimisation because if you set it way too high the controller will still essentially stop at the actually achievable-without-deelay-under-load-increase rate...
The configured minimum rate is the rate below which you consider throughput more important than low latency, that is if the achievable rate is <= min configured rate you accept all latency under load increases. This is less of an optimization and more of a policy question for you to answer.
Finally the base rates are those rates you want the controller to start with if there is no additional information, if you a passimist, set base == min, if you are an optimist set base == max, if you are a realist, set min < base < max If for example you know from speedtests that you normally get say 100 Mbps occasionally it drops to 10, ad it never exceeds 500, you could set:
max: 500
base: 100
min: 10 (assuming that 10 is acceptable, if you use applications like video streaming that requires an average >> 10, say 25 Mbps, then maybe set the minimum to 25+reserve, e.g. 30, but be aware that if your link runs in that regime you will see more latency under load increases).
You might notice that these values are less "scientifically chosen" based on first principles and more policy questions you need to answer for your link and your delay tolerance.
i wonder if i can ask chatgpt to re right this as if i was 10 lol so i can understand im gonna mess with it and see where i like it
im just trying to get lowest latency for fps gaming while everyone els still uses the internet.
I am sorry if this is too convoluted, maybe ask specific questions?
So Minimum=~? (before its too low and can't recover~ from latency being too high due to lack of bandwidth)
Base = Stable bandwidth you expect 70%+ of the time~
Max= Unstable bandwidth but link is capable of getting near
(so when the script detects downloads/streaming it basically ramps towards the max essentially~ ignore the delay-ish)
As per your suggest I've greatly improved my throughout put and latency control, you guys have been amazing.~
as far as i've experienced the ext4 firmware appears to actually work with the script as the squashfs~ appears to hate the living crap out of me as it wasn't working without reinstalling the script every few days...
However it may seem outside of my control it appears that when my download drops to 128kbps during peak the script does not recover. maybe due to isp interference??
(i think my isp may be doing something else to "their" network I'm not a fan of the way ipv6 has been implemented as its... unnecessarily complicated and not exactly compatible for the World Wide Web---since I have no... "manageable" public ipv6)
how can you minimize the cpu usage with this script for a lower end device if it is possible ?
It's always a combination of your WAN's maximum speed and the router's performance you throw at it, ideally the router is always fast enough to cope with sqm/cake at your maximum WAN speed (plus a healthy margin). If your router is slower than (too slow for) that, you'll have to reduce the max value to a limit the router can still deal with comfortably (otherwise the router itself will add delays, as it's overloaded). The approach to find this sweet spot, would be to just try (keeping an eye on htop
and the speedtest/ bufferbloat results) during the testing - start with a high maximum, reduce as much as needed (and a little less than that). You don't need this script for those tests, plain sqm/cake (as it's less dynamic, less of a moving target) and its limits are probably quicker at finding the limits of your device (your findings should still apply to autorate as well).
As moeller0 implied, the end result is always a policy decision, your own - how far you want to go, how much (potential) WAN speed to sacrifice, not because of the ISP being bad (which is bad enough, but rarely something you can change, or you would have already), but 'just' because the router is at its performance limits (something you can change, with faster router hardware).
but the problem is that even when im not generating any traffic whatsoever the cpu is still maxed out
i understand that cake in it self is cpu demanding compared to other shapers , but in this situation it's the script that is maxing out the cpu without any traffic
Yes, that script is requiring some CPU as well, how much, mostly depends on the effective frequency of checking reflectors...but so does the "responsiveness" of the script. One solution is to simply use performant enough hardware for the desired sampling frequency, but that is not helpful for users that already have an otherwise well-working OpenWrt router....
i made a fork with a single commit, using fq_codel/simplest_tbf instead of cake, for those needing lower cpu usage, feel free to try
Howdy all! Hoping to get some help in possibly setting cake up properly for my connection. Not sure what I'm doing wrong, but no matter what I do, my bufferbloat situation is bad on the download side. Enabling cake on the egress side only, the upload bufferbloat is extremely minimal (+5-10ms as opposed to +300 or more without it) yet the download bufferbloat stays the same (+100 and higher) and most times worsens when enabling cake (and autorate as well). I've had a select few times where it's decreased the to +40-50 but that's been rare. I'm mainly concerned with getting latency as stable as possible for gaming.
I'm on AT&T's FirstNet, feeding a Pi 4 which feeds another OpenWRT device as a dumb AP. I average 50-60 megabits down, 12 up on most given days, sometimes maxing at 110, never really anything below 45. I feel as if I am missing something when configuring this but not exactly sure what. I'm no network administrator but I know a few things, this much is beyond me though. I'd appreciate any help anyone has!
I would propose we start simple.... what do you use to initially configure cake, cake-qos-simple or sqm?
Also could you post the output of:
tc -s qdisc
ifstatus wan | grep device
tc -s qdisc
e) re-enable traffic-shaping/cake-autorate
f) tc -s qdisc
g) https://www.waveform.com/tools/bufferbloat
h) https://speed.cloudflare.com
i) tc -s qdisc