[LARTC] Sigh...

Linux Advanced Routing and Traffic Control

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

 



I have the following test script for tc. I have a problem. Nature of which
i will explain at the end of all my config details.

tc qdisc del dev ppp0 root

tc qdisc add dev ppp0 root handle 1:0 cbq bandwidth 1500Kbit avpkt 1000
cell 8
tc class add dev ppp0 parent 1:0 classid 1:1 cbq bandwidth 1500Kbit rate
1450Kbit prio 8 weight 140Kbit allot 1514 cell 8 max
burst 20 avpkt 1000
tc class add dev ppp0 parent 1:1 classid 1:2 cbq bandwidth 1500Kbit rate
1000Kbit prio 5 weight 100Kbit allot 1514 cell 8 max
burst 20 avpkt 1000 bounded
tc class add dev ppp0 parent 1:1 classid 1:3 cbq bandwidth 1500Kbit rate
1200Kbit prio 5 weight 120Kbit allot 1514 cell 8 max
burst 20 avpkt 1000 bounded
tc class add dev ppp0 parent 1:1 classid 1:4 cbq bandwidth 1500Kbit rate
60Kbit prio 5 weight 0.06Mbit allot 1514 cell 8 maxb
urst 20 avpkt 1000 bounded


tc qdisc add dev ppp0 parent 1:2 handle 30: sfq
tc qdisc add dev ppp0 parent 1:3 handle 40: sfq
tc qdisc add dev ppp0 parent 1:4 handle 50: sfq

tc filter add dev ppp0 parent 1:0 protocol ip prio 11 u32 match ip
protocol 1 0xff flowid 1:4


The machien in questions (the one i am writing this on) is a simple
gateway machine that lets my housemates access the internet. It has 3 NICs
connected to the internal net, cable modem and adsl modem. What i was
trying to test with the about setup was to see if I can put a limite on
the adsl interface. After i ran the above test setup ( without any
complains from tc) i then tried to ping random servers on the internet.
Hopeing to test the setup.~~

But nothing happens there is no limit on PING. tc -s filter ls dev ppp0
shows nothing passing through tc not even the root qdisc.

So my question is does TC only works on traffic passing through my
gateway? In that case I am just barking up the wrong tree here. Or is
there something i can do to limit host based traffic.

So my question is does TC only works on traffic passing through my
gateway? In that case I am just barking up the wrong tree here. Or is
there something i can do to limit host based traffic.

Also with my current setup say if i use a filter with fwmark could i limit
my housemate's porn
grabbing bandwidth? Or would i again see tc doing totally nothing?

Thanks

Sebastian Ip




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