|
|
|
|
|
|
|
|
|
|
xen-users
Re: [Xen-users] Linux Traffic Shaping concept for Xen
Anand Gupta wrote:
> Would you mind sharing your tc rules / scripts and how you have used
> them to
> shape traffic for domU's ? Will appreciate the help.
>
> On 1/7/07, Timo Benk <timo.benk@xxxxxx> wrote:
>>
>> why choppy? It works on my side. BTW, no ebtables is needed to achieve
>> traffic shaping. You can stick your tc rules inside Dom0 at the
>> vif-Interfaces of the gateway domain. It is nothing more than tc-magic;-)
You can use the IFB-Device for shaping of the incoming traffic:
(The following tc commands are not tested, but they should give you a
good starting point)
####
## IFB Rules
# modprobe ifb
# tc qdisc add dev eth0 ingress
# tc filter add dev eth0 parent ffff: \
protocol ip prio 10 u32 \
match ip dst 0/0 flowid 1:1 \
action mirred egress redirect dev ifb0
####
## HTB QDiscs
# tc qdisc add dev ifb0 root handle 1:0 htb
# tc class add dev ifb0 parent 1:0 \
classid 1:1 htb \
rate 1mbit mtu 16000 quantum 16000
# tc class add dev ifb0 parent 1:0 \
classid 1:2 htb \
rate 10mbit mtu 16000 quantum 16000
####
## Filter Definitions
# tc filter add dev ifb0 parent 1:0 \
protocol ip prio 1 u32 \
match ip dst 172.17.0.101/32 flowid 1:1
# tc filter add dev ifb0 parent 1:0 \
protocol ip prio 1 u32 \
match ip dst 172.17.0.102/32 flowid 1:2
Greetings,
-timo
--
Timo Benk - Jabber ID: fry@xxxxxxxxxxxx - ICQ ID: #414944731
PGP Public Key: http://www.m28s01.vlinux.de/timo_benk_gpg_key.asc
_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users
|
<Prev in Thread] |
Current Thread |
[Next in Thread>
|
- Re: [Xen-users] Linux Traffic Shaping concept for Xen,
Timo Benk <=
|
|
|
|
|