I want to throttle traffic in my network using tc. What I found if 'wlan0' is from where my internet comes in to my Linux machine and 'eth0' to my internal network.
I've so far found solution for limiting traffic for controlling my connection with internal network. Like, applying rule in 'eth0' for controlling internal network.(using this article http://atmail.com/kb/2009/throttling-bandwidth/)
But what I need to do is to control over 'internal network going to wlan0(internet)' so that Server (my computer) can communicate with client in lan speed and clients can get the bandwidth they need. How to accomplish this using tc ??
I'v tried this.
TC=/sbin/tc IF=eth0 # Interface DNLD=1mbit # DOWNLOAD Limit UPLD=1mbit # UPLOAD Limit IP=188.8.131.52 # Host IP U32="$TC filter add dev $IF protocol ip parent 1:0 prio 1 u32" $TC qdisc add dev $IF root handle 1: htb default 30 $TC class add dev $IF parent 1: classid 1:1 htb rate $DNLD $TC class add dev $IF parent 1: classid 1:2 htb rate $UPLD $U32 match ip dst $IP/32 flowid 1:1 $U32 match ip src $IP/32 flowid 1:2
I am trying to implement tc in cyber cafe application from server to throttle bandwidth of client.