Re: Problem with traffic scheduling using DRR with HTB or with TBF

Linux Advanced Routing and Traffic Control

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



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

On Wed, Feb 18, 2015 at 5:22 PM, rp-user <pinaroland@xxxxxxxxx> wrote:
> 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 majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html



-- 
Dave Täht

thttp://www.bufferbloat.net/projects/bloat/wiki/Upcoming_Talks
--
To unsubscribe from this list: send the line "unsubscribe lartc" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [LARTC Home Page]     [Netfilter]     [Netfilter Development]     [Network Development]     [Bugtraq]     [GCC Help]     [Yosemite News]     [Linux Kernel]     [Fedora Users]
  Powered by Linux