Skip to contentSkip to conversation

htb prioritise trafic

LARTC Adorean Alexandru Raul 2 participants 2 messages Aug 22, 2006

lore
Share & tools
lore
#0 lore raw

I have a router with about 300 clients connecting to it. It has htb with a class per client.

I wnat to create a script to prioritise www trafic and ssh trafic over p2p trafic....

this is a sample of what i have now:

/sbin/tc class add dev eth0 parent 1:5 classid 1:8012 htb rate 35Kbit ceil 281Kbit prio 6
/sbin/tc qdisc add dev eth0 parent 1:8012 handle 8012 sfq perturb 8 /sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 1 u32 match ip src 81.181.180.21 classid 1:8012

/sbin/tc class add dev eth1 parent 1:5 classid 1:8012 htb rate 35Kbit ceil 281Kbit prio 6
/sbin/tc qdisc add dev eth1 parent 1:8012 handle 8012 sfq perturb 8 /sbin/tc filter add dev eth1 parent 1:0 protocol ip prio 1 u32 match ip dst 81.181.180.21 classid 1:8012

this is one client.

I found something on wiki.lug.ro but i could not adapt it to my neads.

Thank you for your time.
_______________________________________________
LARTC mailing list
[email protected]
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc

#1 lore raw
Quoted 21 lines · Adorean Alexandru Raul

I have a router with about 300 clients connecting to it. It has htb with a class per client.

I wnat to create a script to prioritise www trafic and ssh trafic over p2p trafic....

this is a sample of what i have now:

/sbin/tc class add dev eth0 parent 1:5 classid 1:8012 htb rate 35Kbit ceil 281Kbit prio 6
/sbin/tc qdisc add dev eth0 parent 1:8012 handle 8012 sfq perturb 8 /sbin/tc filter add dev eth0 parent 1:0 protocol ip prio 1 u32 match ip src 81.181.180.21 classid 1:8012

/sbin/tc class add dev eth1 parent 1:5 classid 1:8012 htb rate 35Kbit ceil 281Kbit prio 6
/sbin/tc qdisc add dev eth1 parent 1:8012 handle 8012 sfq perturb 8 /sbin/tc filter add dev eth1 parent 1:0 protocol ip prio 1 u32 match ip dst 81.181.180.21 classid 1:8012

Quoted 6 lines

this is one client.

I found something on wiki.lug.ro but i could not adapt it to my neads.

Thank you for your time.

htb-gen[1] does exactly that, in a per-client basis and you can customize what is prio and what is not. And of course all gets automated.

[1]http://freshmeat.net/projects/htb-gen/
PS: There is a new version comming(with lot of improbs)... but in a few weeks. --
Luciano
_______________________________________________
LARTC mailing list
[email protected]
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc