QOS on Tomato Firmware

Soldato
Joined
27 Dec 2006
Posts
2,911
Location
Northampton
Reading more about this I wondering if it does what I expect it to do. I have a MAC address in the household which I want to limit the entire bandwidth control.

Looking at various routers which are compatible with the Tomato firmware, can it be done?
 
Not with QOS. QOS reserves bandwidth for priority applications such as Skype or gaming. You want bandwidth throttling - and I don't know if that's possible with Tomato.
 
Here you go, IP Tables rules to restrict bandwidth usage - paste into Firewall section -


Code:
TCA="tc class add dev br1" 
TFA="tc filter add dev br1" 
TQA="tc qdisc add dev br1" 
SFQ="sfq perturb 10" 
tc qdisc del dev br1 root 
tc qdisc add dev br1 root handle 1: htb 
tc class add dev br1 parent 1: classid 1:1 htb rate [B]1024kbit[/B] 
$TQA parent 1:1 handle 10: $SFQ 
$TFA parent 1:0 prio 2 protocol ip handle 10 fw flowid 1:1 
iptables -t mangle -A POSTROUTING -d [B]192.168.200.0/24[/B] -j MARK --set-mark 10

TCAU="tc class add dev imq0" 
TFAU="tc filter add dev imq0" 
TQAU="tc qdisc add dev imq0" 
insmod imq 
insmod ipt_IMQ 
ip link set imq0 up 
tc qdisc del dev imq0 root 
tc qdisc add dev imq0 root handle 1: htb 
tc class add dev imq0 parent 1: classid 1:1 htb rate [B]512kbit[/B] 
$TQAU parent 1:1 handle 10: $SFQ 
$TFAU parent 1:0 prio 2 protocol ip handle 10 fw flowid 1:1 
iptables -t mangle -A PREROUTING -s [B]192.168.200.0/24[/B] -j MARK --set-mark 10 
iptables -t mangle -A PREROUTING -j IMQ --todev 0

Change the IP Address subnet to the IP address you want to restrict badwidth to

Change the bandwidth for both upload and download as per your requirements (highlighted in the above code)

The above example, download is restricted to 1MBits/sec and upload to 512Kbits/sec
 
Download this version of tomatousb and you have bandwidth control: https://advancedtomato.com/

d4654076ad96d0144199d5945e230d61.png
 
Back
Top Bottom