Linux – QoS configuration for a medium ISP

isplinuxqostc

What is the best Linux-based QoS platform to implement a configuration where all 256Kbps DSL clients (all belong to the same IP range) get a guaranteed speed of 200Kbps with single QoS rule?

Best Answer

The standard linux QoS/traffic control system is called [tc][1] (traffic control).

You will need to initialize a chain, set it's properties, then add your IP's to it, something like this:

#!/bin/bash
DEV=eth0
PATH=$PATH:/sbin
tc qdisc del dev $DEV root
tc qdisc add dev $DEV root handle 1: htb default 20
tc class add dev $DEV parent 1:1 classid 1:10 htb rate 2000kbps ceil 2000kbps burst 500kb quantum 1500
tc qdisc add dev $DEV parent 1:10 handle 10: sfq perturb 10
tc filter add dev $DEV parent 1:0 protocol ip prio 1 u32 match ip dst 10.10.10.1/24 flowid 1:10
tc filter add dev $DEV parent 1:0 protocol ip prio 1 u32 match ip src 10.10.10.1/24 flowid 1:10
Related Topic