Search This Blog

Friday, March 12, 2010

Re: shaping: balancing hosts, then connections

green wrote at 2010-03-12 12:09 -0600:
> One of those groups:
> # ttc class add dev eth0 parent 1:1 classid 1:11 \
> htb rate $( echo "$UP * 0.8" | bc )bps ceil ${UP}bps prio 1
>
> Now this would logically follow:
> # tc qdisc add dev eth0 parent 1:11 handle 11: sfq perturb 10
>
> But I want to balance hosts, not flows/connections, so I include:
> # tc filter add dev eth0 parent 11: handle 1 protocol ip \
> flow hash keys nfct-src divisor 1024
>
> Which I think works. But then multiple connections on a single host are not
> fairly balanced. How can I do that?
>
> More specifically: I would like, for each group like 1:11, to shape traffic in
> this order:
> - source host balance (like SFQ and nfct-src)
> - PRIO qdisc (for TOS especially) for each
> - SFQ (for flows/connections) for each PRIO qdisc
>
> I do not have a static set of source hosts.
>
> Alternative methods are welcome, especially if they accomplish the same thing.

I guess I could script this with HTB and a class for each possible IP because I
do have 2 static subnets...

Is WRR obsolete? Would it help? I have found almost no documentation for it.

No comments: