Netdev List
 help / color / mirror / Atom feed
* HTB behaviour renders cburst feature useless
@ 2007-12-26  5:33 Denys Fedoryshchenko
  0 siblings, 0 replies; only message in thread
From: Denys Fedoryshchenko @ 2007-12-26  5:33 UTC (permalink / raw)
  To: netdev

Hi again

I am trying to use HTB for providing "double" speed shaper. It will looks 
like (graph):

XXXX
XXXX
XXXXYYYY
XXXXYYYY

Explanation:
For example user have bursty rate 1Mbit/s with "bucket"(derived from squid) 
size 10Mbyte, and then he will have 500Kbit/s if bucket is empty. Bucket 
refilled with speed 500Kbit/s. So if user downloading file with size 20Mbyte, 
he will get first 10Mbyte on speed 1Mbit/s, and second part with speed 
500Kbit/s. On TBF i can do this easily, but on HTB it is not trivial, and not 
working as it expected to work.

On HTB i set

#!/bin/sh
tc qdisc        del dev eth0 root
tc qdisc        add dev eth0 handle 1: root htb

#ROOT class is zero, just i am expecting when cburst finished, ceil will not 
be provided.

tc class        add dev eth0 parent 1:0 classid 1:1 htb rate 8bit ceil 8bit 
quantum 1514

#This is values as explained. 
tc class        add dev eth0 parent 1:1 classid 1:3 htb rate 500Kbit ceil 
1Mbit quantum 1514 cburst 10240kb
tc qdisc        add dev eth0 parent 1:3 handle 30 pfifo limit 1

tc filter       add dev eth0 parent 1:0 protocol ip prio 5 u32 match ip src 
192.168.1.1/32 flowid 1:3

But it works not as i am expecting.
1)I can send this 10Mbyte with any speed. It seems will not be limited at 
1Mbit/s.
2)After i reach 10Mbyte traffic will be blocked completely for some time! 
Even queue set as pfifo with 1 packet. It has to be sent with speed 500Kbit 
and all exceeding this value packets has to be dropped. But it is stopping 
whole class traffic completely.


--
Denys Fedoryshchenko
Technical Manager
Virtual ISP S.A.L.


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2007-12-26  5:33 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-12-26  5:33 HTB behaviour renders cburst feature useless Denys Fedoryshchenko

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox