traffic shaping on single ip...

Linux Advanced Routing and Traffic Control

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

 



Hi all. Im using the following CQB shaper to shape IP addresses:
 
DEV=eth1 (internal eth)
 
tc qdisc del dev $DEV root
tc qdisc add dev $DEV root handle 1: cbq avpkt 1000 bandwidth 100mbit
tc class add dev $DEV parent 1: classid 1:1 cbq rate 256kbit allot 1500 prio 5 bounded isolated
tc class add dev $DEV parent 1: classid 1:2 cbq rate 512kbit allot 1500 prio 5 bounded isolated
 
tc filter add dev $DEV parent 1: protocol ip prio 16 u32 match ip dst 192.168.2.230 flowid 1:2
tc filter add dev $DEV parent 1: protocol ip prio 16 u32 match ip src 192.168.2.230 flowid 1:2
 
tc filter add dev $DEV parent 1: protocol ip prio 16 u32 match ip dst 192.168.2.188 flowid 1:1
tc filter add dev $DEV parent 1: protocol ip prio 16 u32 match ip src 192.168.2.188 flowid 1:1
 
tc filter add dev $DEV parent 1: protocol ip prio 16 u32 match ip dst 192.168.2.172 flowid 1:1
tc filter add dev $DEV parent 1: protocol ip prio 16 u32 match ip src 192.168.2.172 flowid 1:1
 
The thing is, i want to be able to shape inbound different from outbound traffic. I use an ADSL line so, i need to shape up significantly lower than down. Thanks a lot.
And also, is there a better way to shape traffic like this? Thanks a lot.
 
Cristiano

[Index of Archives]     [LARTC Home Page]     [Netfilter]     [Netfilter Development]     [Network Development]     [Bugtraq]     [GCC Help]     [Yosemite News]     [Linux Kernel]     [Fedora Users]
  Powered by Linux