Skip to contentSkip to conversation

Problem with traffic scheduling using DRR with HTB or with TBF

DISCUSSION rp-user 3 participants 9 messages Feb 19, 2015 – Feb 27, 2015

lore
Share & tools
lore

rp-user

author
#0 lore raw

Hello
I am using traffic control tools to schedule the outgoing traffic using deficit round robin discipline, maybe there are better alg than drr like codel but deficit-round robin was chosen as case study. the tests are performed on a virtual environment using xen hypervisor. Hereis my scenario:

eth0------| bridge |---------+----- vif1.0 domU 192.168.1.115

                 |                       |
                 |                       +----- vif2.0  domU 2  192.168.1.117
               dom0                  |
                                        +----- vif3.0  domU 3  192.168.1.120
                                         |
                                        +         ...     ...    ...
                                         |
                                        +----  vif10.0 domU 10  192.168.1.127

And i use this config:

tc qdisc add dev eth0 root handle 1: tbf rate 100Mbit burst 5K latency 30ms

tc qdisc add dev eth0 handle 2: parent 1: drr

tc class add dev eth0 parent 2: classid 2:1 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:2 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:3 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:4 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:5 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:6 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:7 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:8 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:9 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:10 drr quantum 1514
######################################
tc qdisc add dev eth0 parent 2:1 handle 10: pfifo limit 1000 tc qdisc add dev eth0 parent 2:2 handle 11: pfifo limit 1000
........... ............ ...........................
................ ...........
tc qdisc add dev eth0 parent 2:9 handle 18: pfifo limit 1000 tc qdisc add dev eth0 parent 2:10 handle 19: pfifo limit 1000
#######################################
tc filter add dev eth0 protocol ip parent 2: prio 1 u32 match ip src 192.168.1.120 classid 2:1
tc filter add dev eth0 protocol ip parent 2: prio 2 u32 match ip src 192.168.1.121 classid 2:2
..... .......... ................. ................ ...............

          ..............  .........          ...............  .......

tc filter add dev eth0 protocol ip parent 2: prio 10 u32 match ip src 192.168.1.117 classid 2:10

For a moment it seems like it was working but after 50sec the bandwith on every virtual machine cut off.
The output of command ' tc -s qdisc show dev eth0 ' generated this output:

qdisc tbf 1: root refcnt 6 rate 100000Kbit burst 5100b lat 30.0ms
Sent 12964998 bytes 8927 pkt (dropped 3159, overlimits 323 requeues 0) backlog 0b 0p requeues 0
qdisc drr 2: parent 1:
Sent 12964998 bytes 8927 pkt (dropped 316, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc pfifo 10: parent 2:1 limit 1000p
Sent 1391636 bytes 966 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc pfifo 11: parent 2:2 limit 1000p
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc pfifo 12: parent 2:3 limit 1000p
Sent 2827908 bytes 1922 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc pfifo 13: parent 2:4 limit 1000p
................ ............. ...........................
............. ................ ................... ........
backlog 0b 0p requeues 0
qdisc pfifo 19: parent 2:10 limit 1000p
Sent 2038816 bytes 1392 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0

to be sure that i didnt have made any mistake i make many test with different conf parameters but no result, as another case i was
considering using htb with drr
as show above:
tc qdisc add dev eth0 root handle 1: htb #######################################################################################| tc class add dev eth0 parent 1: classid 1:1 htb rate 100Mbit ceil 100Mbit #######################################################################################| tc qdisc add dev eth0 parent 1:1 handle 2: drr ##_____________________________________________________________________________________| tc class add dev eth0 parent 2: classid 2:1 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:2 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:3 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:4 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:5 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:6 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:7 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:8 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:9 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:10 drr quantum 1600 ########################################################################################| tc qdisc add dev eth0 parent 2:1 handle 10: bfifo limit 9000
tc qdisc add dev eth0 parent 2:2 handle 11: bfifo limit 9000
tc qdisc add dev eth0 parent 2:3 handle 12: bfifo limit 9000
tc qdisc add dev eth0 parent 2:4 handle 13: bfifo limit 9000
tc qdisc add dev eth0 parent 2:5 handle 14: bfifo limit 9000
tc qdisc add dev eth0 parent 2:6 handle 15: bfifo limit 9000
tc qdisc add dev eth0 parent 2:7 handle 16: bfifo limit 9000
tc qdisc add dev eth0 parent 2:8 handle 17: bfifo limit 9000
tc qdisc add dev eth0 parent 2:9 handle 18: bfifo limit 9000
tc qdisc add dev eth0 parent 2:10 handle 19: bfifo limit 9000 #########################################################################################| #
tc filter add dev eth0 parent 2: protocol ip prio 1 u32 match ip src 192.168.1.120 classid 2:1
tc filter add dev eth0 parent 2: protocol ip prio 2 u32 match ip src 192.168.1.121 classid 2:2
tc filter add dev eth0 parent 2: protocol ip prio 3 u32 match ip src 192.168.1.122 classid 2:3
tc filter add dev eth0 parent 2: protocol ip prio 4 u32 match ip src 192.168.1.123 classid 2:4
tc filter add dev eth0 parent 2: protocol ip prio 5 u32 match ip src 192.168.1.124 classid 2:5
tc filter add dev eth0 parent 2: protocol ip prio 6 u32 match ip src 192.168.1.125 classid 2:6
tc filter add dev eth0 parent 2: protocol ip prio 7 u32 match ip src 192.168.1.126 classid 2:7
tc filter add dev eth0 parent 2: protocol ip prio 8 u32 match ip src 192.168.1.127 classid 2:8
tc filter add dev eth0 parent 2: protocol ip prio 9 u32 match ip src 192.168.1.115 classid 2:9
tc filter add dev eth0 parent 2: protocol ip prio 10 u32 match ip src 192.168.1.117 classid 2:10

but i run "tc -s qdisc show dev eth0 "
disc htb 1: root refcnt 6 r2q 10 default 0 direct_packets_stat 1702133 Sent 2570651055 bytes 1702087 pkt (dropped 11408370, overlimits 0
requeues 1658292)
backlog 0b 0p requeues 1658292
qdisc drr 2: parent 1:1
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 10: parent 2:1 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 11: parent 2:2 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 12: parent 2:3 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 13: parent 2:4 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 14: parent 2:5 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 15: parent 2:6 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 16: parent 2:7 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 17: parent 2:8 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 18: parent 2:9 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 19: parent 2:10 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
It seems like no packet is entering in the qdisc instead they are directly put in htb qdisc without being scheduled by round robin

Which can be the problem in both two situations ?

Thanks in advance
Ronald

#1 lore raw

at first glance, default 0 is wrong for htb. That sends all packets through the default qdisc.

Quoted 181 lines · rp-user

Hello
I am using traffic control tools to schedule the outgoing traffic using deficit round robin discipline, maybe there are better alg than drr like codel but deficit-round robin was chosen as case study. the tests are performed on a virtual environment using xen hypervisor. Hereis my scenario:

eth0------| bridge |---------+----- vif1.0 domU 192.168.1.115

                 |                       |
                 |                       +----- vif2.0  domU 2  192.168.1.117
               dom0                  |
                                        +----- vif3.0  domU 3  192.168.1.120
                                         |
                                        +         ...     ...    ...
                                         |
                                        +----  vif10.0 domU 10  192.168.1.127

And i use this config:

tc qdisc add dev eth0 root handle 1: tbf rate 100Mbit burst 5K latency 30ms

tc qdisc add dev eth0 handle 2: parent 1: drr

tc class add dev eth0 parent 2: classid 2:1 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:2 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:3 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:4 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:5 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:6 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:7 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:8 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:9 drr quantum 1514 tc class add dev eth0 parent 2: classid 2:10 drr quantum 1514
######################################
tc qdisc add dev eth0 parent 2:1 handle 10: pfifo limit 1000 tc qdisc add dev eth0 parent 2:2 handle 11: pfifo limit 1000
........... ............ ...........................
................ ...........
tc qdisc add dev eth0 parent 2:9 handle 18: pfifo limit 1000 tc qdisc add dev eth0 parent 2:10 handle 19: pfifo limit 1000
#######################################
tc filter add dev eth0 protocol ip parent 2: prio 1 u32 match ip src 192.168.1.120 classid 2:1
tc filter add dev eth0 protocol ip parent 2: prio 2 u32 match ip src 192.168.1.121 classid 2:2
..... .......... ................. ................ ...............

          ..............  .........          ...............  .......

tc filter add dev eth0 protocol ip parent 2: prio 10 u32 match ip src 192.168.1.117 classid 2:10

For a moment it seems like it was working but after 50sec the bandwith on every virtual machine cut off.
The output of command ' tc -s qdisc show dev eth0 ' generated this output:

qdisc tbf 1: root refcnt 6 rate 100000Kbit burst 5100b lat 30.0ms
Sent 12964998 bytes 8927 pkt (dropped 3159, overlimits 323 requeues 0) backlog 0b 0p requeues 0
qdisc drr 2: parent 1:
Sent 12964998 bytes 8927 pkt (dropped 316, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc pfifo 10: parent 2:1 limit 1000p
Sent 1391636 bytes 966 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc pfifo 11: parent 2:2 limit 1000p
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc pfifo 12: parent 2:3 limit 1000p
Sent 2827908 bytes 1922 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc pfifo 13: parent 2:4 limit 1000p
................ ............. ...........................
............. ................ ................... ........
backlog 0b 0p requeues 0
qdisc pfifo 19: parent 2:10 limit 1000p
Sent 2038816 bytes 1392 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0

to be sure that i didnt have made any mistake i make many test with different conf parameters but no result, as another case i was
considering using htb with drr
as show above:
tc qdisc add dev eth0 root handle 1: htb #######################################################################################| tc class add dev eth0 parent 1: classid 1:1 htb rate 100Mbit ceil 100Mbit #######################################################################################| tc qdisc add dev eth0 parent 1:1 handle 2: drr ##_____________________________________________________________________________________| tc class add dev eth0 parent 2: classid 2:1 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:2 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:3 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:4 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:5 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:6 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:7 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:8 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:9 drr quantum 1600
tc class add dev eth0 parent 2: classid 2:10 drr quantum 1600 ########################################################################################| tc qdisc add dev eth0 parent 2:1 handle 10: bfifo limit 9000
tc qdisc add dev eth0 parent 2:2 handle 11: bfifo limit 9000
tc qdisc add dev eth0 parent 2:3 handle 12: bfifo limit 9000
tc qdisc add dev eth0 parent 2:4 handle 13: bfifo limit 9000
tc qdisc add dev eth0 parent 2:5 handle 14: bfifo limit 9000
tc qdisc add dev eth0 parent 2:6 handle 15: bfifo limit 9000
tc qdisc add dev eth0 parent 2:7 handle 16: bfifo limit 9000
tc qdisc add dev eth0 parent 2:8 handle 17: bfifo limit 9000
tc qdisc add dev eth0 parent 2:9 handle 18: bfifo limit 9000
tc qdisc add dev eth0 parent 2:10 handle 19: bfifo limit 9000 #########################################################################################| #
tc filter add dev eth0 parent 2: protocol ip prio 1 u32 match ip src 192.168.1.120 classid 2:1
tc filter add dev eth0 parent 2: protocol ip prio 2 u32 match ip src 192.168.1.121 classid 2:2
tc filter add dev eth0 parent 2: protocol ip prio 3 u32 match ip src 192.168.1.122 classid 2:3
tc filter add dev eth0 parent 2: protocol ip prio 4 u32 match ip src 192.168.1.123 classid 2:4
tc filter add dev eth0 parent 2: protocol ip prio 5 u32 match ip src 192.168.1.124 classid 2:5
tc filter add dev eth0 parent 2: protocol ip prio 6 u32 match ip src 192.168.1.125 classid 2:6
tc filter add dev eth0 parent 2: protocol ip prio 7 u32 match ip src 192.168.1.126 classid 2:7
tc filter add dev eth0 parent 2: protocol ip prio 8 u32 match ip src 192.168.1.127 classid 2:8
tc filter add dev eth0 parent 2: protocol ip prio 9 u32 match ip src 192.168.1.115 classid 2:9
tc filter add dev eth0 parent 2: protocol ip prio 10 u32 match ip src 192.168.1.117 classid 2:10

but i run "tc -s qdisc show dev eth0 "
disc htb 1: root refcnt 6 r2q 10 default 0 direct_packets_stat 1702133 Sent 2570651055 bytes 1702087 pkt (dropped 11408370, overlimits 0
requeues 1658292)
backlog 0b 0p requeues 1658292
qdisc drr 2: parent 1:1
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 10: parent 2:1 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 11: parent 2:2 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 12: parent 2:3 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 13: parent 2:4 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 14: parent 2:5 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 15: parent 2:6 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 16: parent 2:7 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 17: parent 2:8 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 18: parent 2:9 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
qdisc bfifo 19: parent 2:10 limit 9000b
Sent 0 bytes 0 pkt (dropped 0, overlimits 0 requeues 0) backlog 0b 0p requeues 0
It seems like no packet is entering in the qdisc instead they are directly put in htb qdisc without being scheduled by round robin

Which can be the problem in both two situations ?

Thanks in advance
Ronald
--
To unsubscribe from this list: send the line "unsubscribe lartc" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

Signature · 3 lines
Dave Täht

thttp://www.bufferbloat.net/projects/bloat/wiki/Upcoming_Talks
author
#2 lore raw
In reply to rp-user

In this case the default qdisc must be 2:10 but which under drr handle 2:
How can i configure this? What do think about the tbf which seems strange when after 50sec all bandwith are dropped.
Regards

Quoted 2 lines · Dave Taht

at first glance, default 0 is wrong for htb. That sends all packets through the default qdisc.

#3 lore raw
In reply to rp-user

Hi , the solution is:

# adding the root qdisc and assign Deficit Round Robin to it
tc qdisc add dev eth0 root handle 1: drr
#
# adding classes to the root qdisc , every class has a quantum of 1514
which represent the frame size

tc class add dev eth0 parent 1: classid 1:1 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:2 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:3 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:4 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:5 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:6 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:7 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:8 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:9 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:10 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:11 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:12 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:13 drr quantum 1514

# assigning a pfifo dqisc with queue size of 256 packets  to every class
       tc qdisc add dev eth0 parent 1:1 handle 1001: pfifo limit 256
       tc qdisc add dev eth0 parent 1:2 handle 12: pfifo limit 256
       tc qdisc add dev eth0 parent 1:3 handle 13: pfifo limit 256
       tc qdisc add dev eth0 parent 1:4 handle 14: pfifo limit 256
       tc qdisc add dev eth0 parent 1:5 handle 15: pfifo limit 256
       tc qdisc add dev eth0 parent 1:6 handle 16: pfifo limit 256
       tc qdisc add dev eth0 parent 1:7 handle 17: pfifo limit 256
       tc qdisc add dev eth0 parent 1:8 handle 18: pfifo limit 256
       tc qdisc add dev eth0 parent 1:9 handle 19: pfifo limit 256
       tc qdisc add dev eth0 parent 1:10 handle 20: pfifo limit 256
       tc qdisc add dev eth0 parent 1:11 handle 21: pfifo limit 256
       tc qdisc add dev eth0 parent 1:12 handle 22: pfifo limit 256
       tc qdisc add dev eth0 parent 1:13 handle 23: pfifo limit 256
#
# every filter match the source ip of every packet and is directed to
the appropriate class
   #the arp filter is very important
  tc filter add dev eth0 protocol arp parent 1:0 prio 1 u32 match u32
0 0 flowid 1:11
#
  tc filter add dev eth0 parent 1:0 protocol ip prio 2 u32 match ip
src 192.168.1.115 classid 1:1
  tc filter add dev eth0 parent 1:0 protocol ip prio 3 u32 match ip
src 192.168.1.117 classid 1:2
  tc filter add dev eth0 parent 1:0 protocol ip prio 4 u32 match ip
src 192.168.1.120 classid 1:3
  tc filter add dev eth0 parent 1:0 protocol ip prio 5 u32 match ip
src 192.168.1.121 classid 1:4
  tc filter add dev eth0 parent 1:0 protocol ip prio 6 u32 match ip
src 192.168.1.122 classid 1:5
  tc filter add dev eth0 parent 1:0 protocol ip prio 7 u32 match ip
src 192.168.1.123 classid 1:6
  tc filter add dev eth0 parent 1:0 protocol ip prio 8 u32 match ip
src 192.168.1.124 classid 1:7
  tc filter add dev eth0 parent 1:0 protocol ip prio 9 u32 match ip
src 192.168.1.125 classid 1:8
  tc filter add dev eth0 parent 1:0 protocol ip prio 10 u32 match ip
src 192.168.1.126 classid 1:9
  tc filter add dev eth0 parent 1:0 protocol ip prio 11 u32 match ip
src 192.168.1.127 classid 1:10
  tc filter add dev eth0 parent 1:0 protocol ip prio 12 u32 match ip
dst 192.168.1.0/24 classid 1:12
  tc filter add dev eth0 parent 1:0 protocol ip prio 13 u32 match ip
dst 0.0.0.0/0 classid 1:13
#
I have tested it and is  working correctly.

Regards

Quoted 11 lines · rp-user

In this case the default qdisc must be 2:10 but which under drr handle 2:
How can i configure this? What do think about the tbf which seems strange when after 50sec all bandwith are dropped.
Regards

Quoted 2 lines · Dave Taht

at first glance, default 0 is wrong for htb. That sends all packets through the default qdisc.

--
To unsubscribe from this list: send the line "unsubscribe lartc" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

#4 lore raw
In reply to rp-user
Quoted 22 lines · Ronald Pina

Hi , the solution is:

# adding the root qdisc and assign Deficit Round Robin to it
tc qdisc add dev eth0 root handle 1: drr
#
# adding classes to the root qdisc , every class has a quantum of 1514
which represent the frame size

tc class add dev eth0 parent 1: classid 1:1 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:2 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:3 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:4 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:5 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:6 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:7 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:8 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:9 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:10 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:11 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:12 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:13 drr quantum 1514

Quoted 14 lines
# assigning a pfifo dqisc with queue size of 256 packets  to every class
       tc qdisc add dev eth0 parent 1:1 handle 1001: pfifo limit 256
       tc qdisc add dev eth0 parent 1:2 handle 12: pfifo limit 256
       tc qdisc add dev eth0 parent 1:3 handle 13: pfifo limit 256
       tc qdisc add dev eth0 parent 1:4 handle 14: pfifo limit 256
       tc qdisc add dev eth0 parent 1:5 handle 15: pfifo limit 256
       tc qdisc add dev eth0 parent 1:6 handle 16: pfifo limit 256
       tc qdisc add dev eth0 parent 1:7 handle 17: pfifo limit 256
       tc qdisc add dev eth0 parent 1:8 handle 18: pfifo limit 256
       tc qdisc add dev eth0 parent 1:9 handle 19: pfifo limit 256
       tc qdisc add dev eth0 parent 1:10 handle 20: pfifo limit 256
       tc qdisc add dev eth0 parent 1:11 handle 21: pfifo limit 256
       tc qdisc add dev eth0 parent 1:12 handle 22: pfifo limit 256
       tc qdisc add dev eth0 parent 1:13 handle 23: pfifo limit 256

Once you get fed up with that, you might want to try fq_codel instead of pfifo, attached to drr, instead. The aggregate packet limit here of 3072? packets is going to give you aggregate bufferbloat big time if you are sending data to all stations at full rate.

Or just codel.

Quoted 47 lines
# every filter match the source ip of every packet and is directed to
the appropriate class
   #the arp filter is very important
  tc filter add dev eth0 protocol arp parent 1:0 prio 1 u32 match u32
0 0 flowid 1:11
#
  tc filter add dev eth0 parent 1:0 protocol ip prio 2 u32 match ip
src 192.168.1.115 classid 1:1
  tc filter add dev eth0 parent 1:0 protocol ip prio 3 u32 match ip
src 192.168.1.117 classid 1:2
  tc filter add dev eth0 parent 1:0 protocol ip prio 4 u32 match ip
src 192.168.1.120 classid 1:3
  tc filter add dev eth0 parent 1:0 protocol ip prio 5 u32 match ip
src 192.168.1.121 classid 1:4
  tc filter add dev eth0 parent 1:0 protocol ip prio 6 u32 match ip
src 192.168.1.122 classid 1:5
  tc filter add dev eth0 parent 1:0 protocol ip prio 7 u32 match ip
src 192.168.1.123 classid 1:6
  tc filter add dev eth0 parent 1:0 protocol ip prio 8 u32 match ip
src 192.168.1.124 classid 1:7
  tc filter add dev eth0 parent 1:0 protocol ip prio 9 u32 match ip
src 192.168.1.125 classid 1:8
  tc filter add dev eth0 parent 1:0 protocol ip prio 10 u32 match ip
src 192.168.1.126 classid 1:9
  tc filter add dev eth0 parent 1:0 protocol ip prio 11 u32 match ip
src 192.168.1.127 classid 1:10
  tc filter add dev eth0 parent 1:0 protocol ip prio 12 u32 match ip
dst 192.168.1.0/24 classid 1:12
  tc filter add dev eth0 parent 1:0 protocol ip prio 13 u32 match ip
dst 0.0.0.0/0 classid 1:13
#
I have tested it and is  working correctly.

Regards

Quoted 11 lines · rp-user

In this case the default qdisc must be 2:10 but which under drr handle 2:
How can i configure this? What do think about the tbf which seems strange when after 50sec all bandwith are dropped.
Regards

Quoted 2 lines · Dave Taht

at first glance, default 0 is wrong for htb. That sends all packets through the default qdisc.

--
To unsubscribe from this list: send the line "unsubscribe lartc" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

Signature · 3 lines
Dave Täht

thttp://www.bufferbloat.net/projects/bloat/wiki/Upcoming_Talks
#5 lore raw
In reply to rp-user

I have been tested DRR using fq_codel and codel in an extremely congested network and I can confirm that the average packet latency has been improved quite well comparing to fifo, the latency is keep at low levels and the throughput tends to be stable.

Quoted 99 lines · Dave Taht
Quoted 22 lines · Ronald Pina

Hi , the solution is:

# adding the root qdisc and assign Deficit Round Robin to it
tc qdisc add dev eth0 root handle 1: drr
#
# adding classes to the root qdisc , every class has a quantum of 1514
which represent the frame size

tc class add dev eth0 parent 1: classid 1:1 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:2 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:3 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:4 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:5 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:6 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:7 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:8 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:9 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:10 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:11 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:12 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:13 drr quantum 1514

Quoted 14 lines
# assigning a pfifo dqisc with queue size of 256 packets  to every class
       tc qdisc add dev eth0 parent 1:1 handle 1001: pfifo limit 256
       tc qdisc add dev eth0 parent 1:2 handle 12: pfifo limit 256
       tc qdisc add dev eth0 parent 1:3 handle 13: pfifo limit 256
       tc qdisc add dev eth0 parent 1:4 handle 14: pfifo limit 256
       tc qdisc add dev eth0 parent 1:5 handle 15: pfifo limit 256
       tc qdisc add dev eth0 parent 1:6 handle 16: pfifo limit 256
       tc qdisc add dev eth0 parent 1:7 handle 17: pfifo limit 256
       tc qdisc add dev eth0 parent 1:8 handle 18: pfifo limit 256
       tc qdisc add dev eth0 parent 1:9 handle 19: pfifo limit 256
       tc qdisc add dev eth0 parent 1:10 handle 20: pfifo limit 256
       tc qdisc add dev eth0 parent 1:11 handle 21: pfifo limit 256
       tc qdisc add dev eth0 parent 1:12 handle 22: pfifo limit 256
       tc qdisc add dev eth0 parent 1:13 handle 23: pfifo limit 256

Once you get fed up with that, you might want to try fq_codel instead of pfifo, attached to drr, instead. The aggregate packet limit here of 3072? packets is going to give you aggregate bufferbloat big time if you are sending data to all stations at full rate.

Or just codel.

Quoted 33 lines
# every filter match the source ip of every packet and is directed to
the appropriate class
   #the arp filter is very important
  tc filter add dev eth0 protocol arp parent 1:0 prio 1 u32 match u32
0 0 flowid 1:11
#
  tc filter add dev eth0 parent 1:0 protocol ip prio 2 u32 match ip
src 192.168.1.115 classid 1:1
  tc filter add dev eth0 parent 1:0 protocol ip prio 3 u32 match ip
src 192.168.1.117 classid 1:2
  tc filter add dev eth0 parent 1:0 protocol ip prio 4 u32 match ip
src 192.168.1.120 classid 1:3
  tc filter add dev eth0 parent 1:0 protocol ip prio 5 u32 match ip
src 192.168.1.121 classid 1:4
  tc filter add dev eth0 parent 1:0 protocol ip prio 6 u32 match ip
src 192.168.1.122 classid 1:5
  tc filter add dev eth0 parent 1:0 protocol ip prio 7 u32 match ip
src 192.168.1.123 classid 1:6
  tc filter add dev eth0 parent 1:0 protocol ip prio 8 u32 match ip
src 192.168.1.124 classid 1:7
  tc filter add dev eth0 parent 1:0 protocol ip prio 9 u32 match ip
src 192.168.1.125 classid 1:8
  tc filter add dev eth0 parent 1:0 protocol ip prio 10 u32 match ip
src 192.168.1.126 classid 1:9
  tc filter add dev eth0 parent 1:0 protocol ip prio 11 u32 match ip
src 192.168.1.127 classid 1:10
  tc filter add dev eth0 parent 1:0 protocol ip prio 12 u32 match ip
dst 192.168.1.0/24 classid 1:12
  tc filter add dev eth0 parent 1:0 protocol ip prio 13 u32 match ip
dst 0.0.0.0/0 classid 1:13
#
I have tested it and is  working correctly.
Quoted 14 lines

Regards

Quoted 11 lines · rp-user

In this case the default qdisc must be 2:10 but which under drr handle 2:
How can i configure this? What do think about the tbf which seems strange when after 50sec all bandwith are dropped.
Regards

Quoted 2 lines · Dave Taht

at first glance, default 0 is wrong for htb. That sends all packets through the default qdisc.

--
To unsubscribe from this list: send the line "unsubscribe lartc" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

--
Dave Täht

thttp://www.bufferbloat.net/projects/bloat/wiki/Upcoming_Talks

#6 lore raw
In reply to rp-user
Quoted 4 lines · Ronald Pina

I have been tested DRR using fq_codel and codel in an extremely congested network and I can confirm that the average packet latency has been improved quite well comparing to fifo, the latency is keep at low levels and the throughput tends to be stable.

Isn't it awesome? We can replace the phone system now...

I try to encourage people to use netperf-wrapper to give easy comparison charts from repeatable tests. Did you try that?

Quoted 100 lines · Dave Taht
Quoted 99 lines · Ronald Pina
Quoted 22 lines

Hi , the solution is:

# adding the root qdisc and assign Deficit Round Robin to it
tc qdisc add dev eth0 root handle 1: drr
#
# adding classes to the root qdisc , every class has a quantum of 1514
which represent the frame size

tc class add dev eth0 parent 1: classid 1:1 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:2 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:3 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:4 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:5 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:6 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:7 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:8 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:9 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:10 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:11 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:12 drr quantum 1514 tc class add dev eth0 parent 1: classid 1:13 drr quantum 1514

Quoted 14 lines
# assigning a pfifo dqisc with queue size of 256 packets  to every class
       tc qdisc add dev eth0 parent 1:1 handle 1001: pfifo limit 256
       tc qdisc add dev eth0 parent 1:2 handle 12: pfifo limit 256
       tc qdisc add dev eth0 parent 1:3 handle 13: pfifo limit 256
       tc qdisc add dev eth0 parent 1:4 handle 14: pfifo limit 256
       tc qdisc add dev eth0 parent 1:5 handle 15: pfifo limit 256
       tc qdisc add dev eth0 parent 1:6 handle 16: pfifo limit 256
       tc qdisc add dev eth0 parent 1:7 handle 17: pfifo limit 256
       tc qdisc add dev eth0 parent 1:8 handle 18: pfifo limit 256
       tc qdisc add dev eth0 parent 1:9 handle 19: pfifo limit 256
       tc qdisc add dev eth0 parent 1:10 handle 20: pfifo limit 256
       tc qdisc add dev eth0 parent 1:11 handle 21: pfifo limit 256
       tc qdisc add dev eth0 parent 1:12 handle 22: pfifo limit 256
       tc qdisc add dev eth0 parent 1:13 handle 23: pfifo limit 256

Once you get fed up with that, you might want to try fq_codel instead of pfifo, attached to drr, instead. The aggregate packet limit here of 3072? packets is going to give you aggregate bufferbloat big time if you are sending data to all stations at full rate.

Or just codel.

Quoted 33 lines
# every filter match the source ip of every packet and is directed to
the appropriate class
   #the arp filter is very important
  tc filter add dev eth0 protocol arp parent 1:0 prio 1 u32 match u32
0 0 flowid 1:11
#
  tc filter add dev eth0 parent 1:0 protocol ip prio 2 u32 match ip
src 192.168.1.115 classid 1:1
  tc filter add dev eth0 parent 1:0 protocol ip prio 3 u32 match ip
src 192.168.1.117 classid 1:2
  tc filter add dev eth0 parent 1:0 protocol ip prio 4 u32 match ip
src 192.168.1.120 classid 1:3
  tc filter add dev eth0 parent 1:0 protocol ip prio 5 u32 match ip
src 192.168.1.121 classid 1:4
  tc filter add dev eth0 parent 1:0 protocol ip prio 6 u32 match ip
src 192.168.1.122 classid 1:5
  tc filter add dev eth0 parent 1:0 protocol ip prio 7 u32 match ip
src 192.168.1.123 classid 1:6
  tc filter add dev eth0 parent 1:0 protocol ip prio 8 u32 match ip
src 192.168.1.124 classid 1:7
  tc filter add dev eth0 parent 1:0 protocol ip prio 9 u32 match ip
src 192.168.1.125 classid 1:8
  tc filter add dev eth0 parent 1:0 protocol ip prio 10 u32 match ip
src 192.168.1.126 classid 1:9
  tc filter add dev eth0 parent 1:0 protocol ip prio 11 u32 match ip
src 192.168.1.127 classid 1:10
  tc filter add dev eth0 parent 1:0 protocol ip prio 12 u32 match ip
dst 192.168.1.0/24 classid 1:12
  tc filter add dev eth0 parent 1:0 protocol ip prio 13 u32 match ip
dst 0.0.0.0/0 classid 1:13
#
I have tested it and is  working correctly.
Quoted 14 lines

Regards

Quoted 11 lines · rp-user

In this case the default qdisc must be 2:10 but which under drr handle 2:
How can i configure this? What do think about the tbf which seems strange when after 50sec all bandwith are dropped.
Regards

Quoted 2 lines · Dave Taht

at first glance, default 0 is wrong for htb. That sends all packets through the default qdisc.

--
To unsubscribe from this list: send the line "unsubscribe lartc" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

--
Dave Täht

thttp://www.bufferbloat.net/projects/bloat/wiki/Upcoming_Talks

Signature · 4 lines
Dave Täht
Let's make wifi fast, less jittery and reliable again!

https://plus.google.com/u/0/107942175615993706558/posts/TVX3o84jjmb
#7 lore raw
In reply to rp-user

It obvious that fixing bufferbloat problems has made great steps toward, the throughput overhead of fq_codel is a at low levels and can be negligible compared to the its advantages , I can submit some chart to this topic as soon as i get some free time...

Regards

Quoted 10 lines · Dave Taht
Quoted 4 lines · Ronald Pina

I have been tested DRR using fq_codel and codel in an extremely congested network and I can confirm that the average packet latency has been improved quite well comparing to fifo, the latency is keep at low levels and the throughput tends to be stable.

Isn't it awesome? We can replace the phone system now...

I try to encourage people to use netperf-wrapper to give easy comparison charts from repeatable tests. Did you try that?

#8 lore raw
In reply to rp-user
Quoted 6 lines · Ronald Pina

It obvious that fixing bufferbloat problems has made great steps toward, the throughput overhead of fq_codel is a at low levels and can be negligible compared to the its advantages , I can submit some chart to this topic as soon as i get some free time...

Regards

Awesome. More independent benchmarks and testing is really needed, by people new to the concepts. I appreciate whatever you can do.

One more - fun - item, is to try enabling ecn on your tcps and running that through fq_codel (which has ecn enabled by default). That is a single sysctl on both sides of the connection:

net.ipv4.tcp_ecn=1

that hits the trifecta - low latency, high throughput, and zero packet loss.

We just have a few billion machines to upgrade.

Quoted 12 lines · Dave Taht
Quoted 10 lines · Ronald Pina
Quoted 4 lines

I have been tested DRR using fq_codel and codel in an extremely congested network and I can confirm that the average packet latency has been improved quite well comparing to fifo, the latency is keep at low levels and the throughput tends to be stable.

Isn't it awesome? We can replace the phone system now...

I try to encourage people to use netperf-wrapper to give easy comparison charts from repeatable tests. Did you try that?

Signature · 4 lines
Dave Täht
Let's make wifi fast, less jittery and reliable again!

https://plus.google.com/u/0/107942175615993706558/posts/TVX3o84jjmb