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

Re: Problems with CBQ and problems with isolated/bounded



Hi, Suhail,

Some commments to your questions and your script.

Suhail wrote:

>
>
>   1. However when I suddenly stop a stream ( any of the 3 streams )
>      ...... The total BW goes down to less than 1Mbit/s and the CBQ
>      rules are not followed at all.
>

Don't know why. Anyway, make sure you are using the "weight" parameter
correctly (see below).

>   1.
>
>   1. Moreover when all the priorities of the the the three cbq classes
>      (1:10, 1:20, 1:30 ) are set to be the same ( I tried keeping all
>      to be 1 ) again the same effect is observed ..... i.e. cbq gets
>      all messed up.
>

This may have to do with "weight". "weight" comes into play when there
are two flows of the same priority at the same time. At this moment,
given that allot is the same for both flows, the bandwidth is allocated
in proportion to weight.

I don't remember the exact formula (any help here, guys?). Anyway, try
to make "weight" equal or proportional to "rate". (see my remarks to
your script, below).

>   1. Also when if I have different priorities for all streams and
>      instead of using bounded+isolated for each class I use only
>      isolated, the class with the highest priority ( lowest prio
>      number)    hogs up all the bandwidth.
>

I have not been able to make "isolated" work properly. :(

> -----------------------------------------------------------------------
>
> ## Attach a queuing discipline to the dev eth1
> tc qdisc add dev eth1 root handle 1: cbq bandwidth 10Mbit allot 1514
> cell 8 \
> avpkt 1000 mpu 64
>
> #Define the root class
> #tc class add dev eth1 classid 1:1 parent 1:0 cbq bandwidth 10Mbit
> avpkt 1000 \
> # mpu 64  rate 10Mbit allot 1514 weight 1 prio 8
>
> #Define the 3 classes with each having a sfq queue
> tc class add dev eth1 classid 1:10 parent 1:0 cbq bandwidth 10Mbit
> avpkt 1000 \
>  mpu 64  rate 5Mbit bounded allot 1514 weight 1 prio 1

Try "weight 5" here.

>
>
> tc qdisc add dev eth1 parent 1:10 sfq quantum 1514b perturb 15
>
>
> tc class add dev eth1 classid 1:20 parent 1:0 cbq bandwidth 10Mbit
> avpkt 1000 \
>  mpu 64 rate 3Mbit  bounded allot 1514 weight 1 prio 3

try "weight 3"


>
> tc qdisc add dev eth1 parent 1:20 sfq quantum 1514b perturb 15
>
> tc class add dev eth1 classid 1:30 parent 1:0 cbq bandwidth 10Mbit
> avpkt 1000 \
>  mpu 64 rate 2Mbit  bounded allot 1514 weight 1 prio 5

"weight 2"

>
> tc qdisc add dev eth1 parent 1:30 sfq quantum 1514b perturb 15
>
>

Regards,

Mariano