Brian J. Murrell said:
> I really don't seem to be getting this.  ~sigh~

It'll come with time.

> As I wrote before I'm not interested in dividing bandwidth up, just
> prioritizing the use of the full bandwidth by all-comers.

Yes.

> So I figure I want a TBF in my root class to prevent the queue in my DSL
> modem from filling up.  I have about 128kb/s upstream so I added:
>
> # tc qdisc add dev ppp0 root handle 1: tbf rate 120kbit latency 50ms burst
> 1540

Precisely what I have done, but I only specified rate and left the rest to
the defaults.

> (not sure what values I want for latency and burst)
>
> Then I figure I want a PRIO classifier with 3 bands.  I want anything
> not otherwise matching a filter to go in band 2, known bulk to go in
> band 3 and priority, latency sensitive "interactive" stuff (i.e. ssh,
> not scp) to go in band 1:

That's pretty common and should work fine.

> # tc qdisc add dev ppp0 parent 1: handle 10: prio
>
> And then only because some examples showed using it, I put an SFQ in
> each band.  Do I really need this?  Should I not do this step?
>
> # tc qdisc add dev ppp0 parent 10:1 handle 100: sfq
> # tc qdisc add dev ppp0 parent 10:2 handle 200: sfq
> # tc qdisc add dev ppp0 parent 10:3 handle 300: sfq

It depends.  The default sfq had a large queue of 128 which may be too big
for interactive traffic.  That said, I ultimately chose to use sfq for all
my classes.  (p2p was unhappy especially with a straight pfifo with so many
connections being made.)

> Now I want to use iptables to put stuff into the different bands.
> Again, by example I have been trying to do some iptables rules with -j
> CLASSIFY --set-class (this one to get ping to be processed in the
> highest priority band to test the effectiveness of "interactive
> traffic):
>
> # iptables -t mangle -I POSTROUTING -p icmp --icmp-type echo-request -j
> CLASSIFY --set-class 10:100
>
> I'm not sure what the class numbers I should be using.  Would they be
> 10:100, 10:200 and 10:300 for the 3 bands?  or 10:1, 10:2 and 10:3?

10:1 .. 10:3 should work.

You could read my whole traffic control guide as it covers all these basics
and it might help some since my goal was a configuration similar to yours.

http://edseek.com/~jasonb/articles/traffic_shaping/



_______________________________________________
LARTC mailing list
LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc

Reply via email to