I built a real-time web UI for CAKE SQM stats

Hi @JackH ,

Thanks for the follow up.

Can you give me the output of tc -s qdisc from your OpenWrt?
Since my OpenWrt doesn't support cake_mq yet, it'd be great to see the full output of tc -s qdisc from a real machine running cake_mq.

For example, this is how tc -s qdisc looks like on my machine:

root@galpt:~# tc -s qdisc
qdisc noqueue 0: dev lo root refcnt 2 
 Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) 
 backlog 0b 0p requeues 0
qdisc fq_codel 0: dev eth0 root refcnt 2 limit 10240p flows 1024 quantum 1514 target 5ms interval 100ms memory_limit 32Mb ecn drop_batch 64 
 Sent 26200902060 bytes 22740323 pkt (dropped 0, overlimits 0 requeues 121) 
 backlog 0b 0p requeues 121
  maxpacket 65102 drop_overlimit 0 new_flow_count 1395 ecn_mark 0
  new_flows_len 0 old_flows_len 0
qdisc cake 8009: dev eth1 root refcnt 2 bandwidth 50Mbit diffserv4 dual-srchost nat nowash no-ack-filter split-gso rtt 100ms atm overhead 48 memlimit 32Mb 
 Sent 3324338975 bytes 10822688 pkt (dropped 4472, overlimits 9456974 requeues 0) 
 backlog 0b 0p requeues 0
 memory used: 999616b of 32Mb
 capacity estimate: 50Mbit
 min/max network layer size:           28 /    1500
 min/max overhead-adjusted size:      106 /    1749
 average network hdr offset:           14

                   Bulk  Best Effort        Video        Voice
  thresh       3125Kbit       50Mbit       25Mbit    12500Kbit
  target         5.81ms          5ms          5ms          5ms
  interval        101ms        100ms        100ms        100ms
  pk_delay          0us        105us         93us        107us
  av_delay          0us         15us         13us         21us
  sp_delay          0us          3us          3us          2us
  backlog            0b           0b           0b           0b
  pkts                0     10787255         1085        38820
  bytes               0   3324004264        80020      6359078
  way_inds            0       301686            0         3515
  way_miss            0       171575          535         1161
  way_cols            0            0            0            0
  drops               0         4472            0            0
  marks               0           15            0            0
  ack_drop            0            0            0            0
  sp_flows            0            4            1            1
  bk_flows            0            1            0            0
  un_flows            0            0            0            0
  max_len             0        68338          551          590
  quantum           300         1514          762          381

qdisc ingress ffff: dev eth1 parent ffff:fff1 ---------------- 
 Sent 25828489779 bytes 22829480 pkt (dropped 0, overlimits 0 requeues 0) 
 backlog 0b 0p requeues 0
qdisc noqueue 0: dev br-lan root refcnt 2 
 Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) 
 backlog 0b 0p requeues 0
qdisc cake 800a: dev ifb4eth1 root refcnt 2 bandwidth 50Mbit diffserv4 dual-dsthost nat nowash ingress no-ack-filter split-gso rtt 100ms atm overhead 48 memlimit 32Mb 
 Sent 26119960453 bytes 22560008 pkt (dropped 269472, overlimits 26868693 requeues 0) 
 backlog 0b 0p requeues 0
 memory used: 3610880b of 32Mb
 capacity estimate: 50Mbit
 min/max network layer size:           46 /    1500
 min/max overhead-adjusted size:      106 /    1749
 average network hdr offset:           14

                   Bulk  Best Effort        Video        Voice
  thresh       3125Kbit       50Mbit       25Mbit    12500Kbit
  target         5.81ms          5ms          5ms          5ms
  interval        101ms        100ms        100ms        100ms
  pk_delay         12us        771us        402us         60us
  av_delay          0us        158us         44us         16us
  sp_delay          0us          9us          9us          6us
  backlog            0b           0b           0b           0b
  pkts                5     22649757        38670       141048
  bytes             300  26337291765     20005769    129512851
  way_inds            0       323940            3            0
  way_miss            3       162156         1180          106
  way_cols            0            0            0            0
  drops               0       269236           27          209
  marks               0        76839            0            0
  ack_drop            0            0            0            0
  sp_flows            1            3            1            1
  bk_flows            0            1            0            0
  un_flows            0            0            0            0
  max_len            60        68338        62112        21690
  quantum           300         1514          762          381

root@galpt:~# 

And this is how tc -s -j qdisc looks like on my machine

root@galpt:~# tc -s -j qdisc
[{"kind":"noqueue","handle":"0:","dev":"lo","root":true,"refcnt":2,"options":{},"bytes":0,"packets":0,"drops":0,"overlimits":0,"requeues":0,"backlog":0,"qlen":0},{"kind":"fq_codel","handle":"0:","dev":"eth0","root":true,"refcnt":2,"options":{"limit":10240,"flows":1024,"quantum":1514,"target":4999,"interval":99999,"memory_limit":33554432,"ecn":true,"drop_batch":64},"bytes":26232176640,"packets":22767387,"drops":0,"overlimits":0,"requeues":122,"backlog":0,"qlen":0,"maxpacket":65102,"drop_overlimit":0,"new_flow_count":1398,"ecn_mark":0,"new_flows_len":0,"old_flows_len":0},{"kind":"cake","handle":"8009:","dev":"eth1","root":true,"refcnt":2,"options":{"bandwidth":6250000,"diffserv":"diffserv4","flowmode":"dual-srchost","nat":true,"wash":false,"ingress":false,"ack-filter":"disabled","split_gso":true,"rtt":100000,"raw":false,"atm":"atm","overhead":48,"memlimit":33554432,"fwmark":"0"},"bytes":3325602533,"packets":10832451,"drops":4472,"overlimits":9462093,"requeues":0,"backlog":0,"qlen":0,"memory_used":999616,"memory_limit":33554432,"capacity_estimate":6250000,"min_network_size":28,"max_network_size":1500,"min_adj_size":106,"max_adj_size":1749,"avg_hdr_offset":14,"tins":[{"threshold_rate":390625,"sent_bytes":0,"backlog_bytes":0,"target_us":5813,"interval_us":100813,"peak_delay_us":0,"avg_delay_us":0,"base_delay_us":0,"sent_packets":0,"way_indirect_hits":0,"way_misses":0,"way_collisions":0,"drops":0,"ecn_mark":0,"ack_drops":0,"sparse_flows":0,"bulk_flows":0,"unresponsive_flows":0,"max_pkt_len":0,"flow_quantum":300},{"threshold_rate":6250000,"sent_bytes":3325249265,"backlog_bytes":0,"target_us":5000,"interval_us":100000,"peak_delay_us":79,"avg_delay_us":9,"base_delay_us":1,"sent_packets":10796962,"way_indirect_hits":301796,"way_misses":171929,"way_collisions":0,"drops":4472,"ecn_mark":15,"ack_drops":0,"sparse_flows":3,"bulk_flows":1,"unresponsive_flows":0,"max_pkt_len":68338,"flow_quantum":1514},{"threshold_rate":3125000,"sent_bytes":80200,"backlog_bytes":0,"target_us":5000,"interval_us":100000,"peak_delay_us":92,"avg_delay_us":13,"base_delay_us":3,"sent_packets":1087,"way_indirect_hits":0,"way_misses":537,"way_collisions":0,"drops":0,"ecn_mark":0,"ack_drops":0,"sparse_flows":1,"bulk_flows":0,"unresponsive_flows":0,"max_pkt_len":551,"flow_quantum":762},{"threshold_rate":1562500,"sent_bytes":6377455,"backlog_bytes":0,"target_us":5000,"interval_us":100000,"peak_delay_us":99,"avg_delay_us":20,"base_delay_us":2,"sent_packets":38874,"way_indirect_hits":3515,"way_misses":1161,"way_collisions":0,"drops":0,"ecn_mark":0,"ack_drops":0,"sparse_flows":1,"bulk_flows":0,"unresponsive_flows":0,"max_pkt_len":590,"flow_quantum":381}]},{"kind":"ingress","handle":"ffff:","dev":"eth1","parent":"ffff:fff1","options":{},"bytes":25858899448,"packets":22856281,"drops":0,"overlimits":0,"requeues":0,"backlog":0,"qlen":0},{"kind":"noqueue","handle":"0:","dev":"br-lan","root":true,"refcnt":2,"options":{},"bytes":0,"packets":0,"drops":0,"overlimits":0,"requeues":0,"backlog":0,"qlen":0},{"kind":"cake","handle":"800a:","dev":"ifb4eth1","root":true,"refcnt":2,"options":{"bandwidth":6250000,"diffserv":"diffserv4","flowmode":"dual-dsthost","nat":true,"wash":false,"ingress":true,"ack-filter":"disabled","split_gso":true,"rtt":100000,"raw":false,"atm":"atm","overhead":48,"memlimit":33554432,"fwmark":"0"},"bytes":26151190088,"packets":22586809,"drops":269472,"overlimits":26891052,"requeues":0,"backlog":0,"qlen":0,"memory_used":3610880,"memory_limit":33554432,"capacity_estimate":6250000,"min_network_size":46,"max_network_size":1500,"min_adj_size":106,"max_adj_size":1749,"avg_hdr_offset":14,"tins":[{"threshold_rate":390625,"sent_bytes":300,"backlog_bytes":0,"target_us":5813,"interval_us":100813,"peak_delay_us":12,"avg_delay_us":0,"base_delay_us":0,"sent_packets":5,"way_indirect_hits":0,"way_misses":3,"way_collisions":0,"drops":0,"ecn_mark":0,"ack_drops":0,"sparse_flows":1,"bulk_flows":0,"unresponsive_flows":0,"max_pkt_len":60,"flow_quantum":300},{"threshold_rate":6250000,"sent_bytes":26368514979,"backlog_bytes":0,"target_us":5000,"interval_us":100000,"peak_delay_us":702,"avg_delay_us":357,"base_delay_us":28,"sent_packets":22676477,"way_indirect_hits":324209,"way_misses":162509,"way_collisions":0,"drops":269236,"ecn_mark":76839,"ack_drops":0,"sparse_flows":3,"bulk_flows":1,"unresponsive_flows":0,"max_pkt_len":68338,"flow_quantum":1514},{"threshold_rate":3125000,"sent_bytes":20007810,"backlog_bytes":0,"target_us":5000,"interval_us":100000,"peak_delay_us":370,"avg_delay_us":44,"base_delay_us":6,"sent_packets":38694,"way_indirect_hits":3,"way_misses":1180,"way_collisions":0,"drops":27,"ecn_mark":0,"ack_drops":0,"sparse_flows":1,"bulk_flows":0,"unresponsive_flows":0,"max_pkt_len":62112,"flow_quantum":762},{"threshold_rate":1562500,"sent_bytes":129517231,"backlog_bytes":0,"target_us":5000,"interval_us":100000,"peak_delay_us":51,"avg_delay_us":16,"base_delay_us":5,"sent_packets":141105,"way_indirect_hits":0,"way_misses":106,"way_collisions":0,"drops":209,"ecn_mark":0,"ack_drops":0,"sparse_flows":1,"bulk_flows":0,"unresponsive_flows":0,"max_pkt_len":21690,"flow_quantum":381}]}]
root@galpt:~# 

I'll need both the output of tc -s qdisc and tc -s -j qdisc, will try to check if this is a bug or not.