A question regarding traffic shaping involving tc-tbf and tc-sfq

Submitted by Anonymous
on June 26, 2008 - 9:20am

Hello all,

Apologies in advance if it's a stupid question, but I can't find its solution anywhere else. I am trying to shape network traffic on an interface (100Mbps) which should only permit 1.5Mbps bandwidth and has sfq filter attached to it. I have used the following tc qdiscs.

$ tc qdisc replace dev eth2 root handle 1: tbf rate 1mbit burst 8kb limit 4096kb peakrate 1.5mbit minburst 1540
$ tc qdisc add dev eth2 parent 1:1 sfq perturb 10 quantum 1514

The problem is that apparently, the bandwidth is not being reduced with the above-mentioned setup. When I have just the token bucket installed, my experiments show that the download rate is far slower than the case when these are rules are used.

What am I doing wrong? Thanks in advance.

Try with htb+sfq ?

Anonymous (not verified)
on
June 29, 2008 - 11:58pm

Not sure what you're doing wrong, I have not looked at tbf in a few years and it was only useable as a leaf class at that time.

However, I would suggest you try running sfq under an htb qdisc. This is a more typical configuration and it works fine for me. With a single subclass htb is similar to what you were using tbf for, and you also get to add multiple subclasses if you ever need to.

Hope this helps. You should not have trouble finding help on htb+sfq setup, or you can ask again here too...

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.