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

Re: [Xen-users] [Xen-devel] Q&A question: Dynamic Network Throttling?



I meant to add ...

Basic config. Configure a tree of HTB classes like this :

First configure a root attached to the interface :
tc class add dev ethext parent 1: classid 1:1 htb rate $OutSpeed burst 20k 
cburst 20k

In my setup, I have multiple groups of classes, so I have a brach for each 
group :
tc class add dev ethext parent 1:1 classid 1:10 htb rate 6144kbit ceil 
$OutCeilDef burst 16k cburst 16k prio 1
You can leave this out and just make the parent of the following classes id 1

Then within this group I have a set of leafs :
tc class add dev ethext parent 1:10 classid 1:11 htb rate 1024kbit ceil 
$OutCeilDef burst 12k cburst 12k prio 1
tc class add dev ethext parent 1:10 classid 1:12 htb rate 4096kbit ceil 
$OutCeilDef burst 12k cburst 12k prio 2
tc class add dev ethext parent 1:10 classid 1:13 htb rate 512kbit ceil 
$OutCeilDef burst 12k cburst 12k prio 3
tc class add dev ethext parent 1:10 classid 1:14 htb rate 512kbit ceil 6144kbit 
burst 12k cburst 12k prio 4

Then within each leaf, we run a fair queuing discipline :
tc qdisc add dev ethext parent 1:11 handle 11: sfq perturb 10
tc qdisc add dev ethext parent 1:12 handle 12: sfq perturb 10
tc qdisc add dev ethext parent 1:13 handle 13: sfq perturb 10
tc qdisc add dev ethext parent 1:14 handle 14: sfq perturb 10

For each class, you set the rate to be what you want to be available under 
"full load", and ceiling to what you want any class to be able to go to when 
other classes aren't using their full allocation. Just make sure that for each 
branch in the tree, the sum of the rates of the children does not exceed that 
of the parent - ie it's no good throttling a group of (say) 4 guests to 10Mbps 
each, if the parent then throttles to (say) 30Mbps. The parent will then 
throttle separately, meaning that the individual child queues won't be able to 
work properly.


_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxx
http://lists.xen.org/xen-users


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.