* Re: [LARTC] htb parameter problem
2003-03-07 6:36 [LARTC] htb parameter problem liang jian
@ 2003-03-07 6:55 ` Martin A. Brown
2003-03-07 8:53 ` liang jian
` (7 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Martin A. Brown @ 2003-03-07 6:55 UTC (permalink / raw)
To: lartc
: tc class add dev eth1 parent 30:100 classid 30:1000 \
: htb rate 12800kbps ceil 51200kbps prio 1
: tc qdisc add dev eth1 parent 30:1000 sfq
Whoa!! Are you *sure* you mean 12800 kilobytes per second and 51200 kilo
bytes per second? Just double-checking.
This sort of number looks quite similar to what I call a 128k / 512k line.
I would specify these rates as follows:
128kbit and 512kbit
But maybe you really mean:
12800kbit and 51200kbit
Judging from your "tc -s" output, you have a large pipe to the 'net.
: How to do obtain below result:
: I read from www.docum.org have problem about parameter:
Which parameter are you asking about? You don't provide much information
to us about what your question or concern is.
Is quantum the problem? Or burst, cburst.
: Frist :
:
: The same story goes for ceil and cburst, you don't want the class to
: send more packets then it's ceil allows. So removing the cburst is a
: good choice for that case.
:
: Second:
:
: Packets that are sent when the class is allowed to send, are still
: matched against rate/ceil/burst/cburst. So a big quantum will not
: create bursts if you don't allow it with the burs/cburst parameters.
Help us understand what your question is, Liang. Thank you,
-Martin
--
Martin A. Brown --- SecurePipe, Inc. --- mabrown@securepipe.com
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: [LARTC] htb parameter problem
2003-03-07 6:36 [LARTC] htb parameter problem liang jian
2003-03-07 6:55 ` Martin A. Brown
@ 2003-03-07 8:53 ` liang jian
2003-03-08 19:39 ` Stef Coene
` (6 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: liang jian @ 2003-03-07 8:53 UTC (permalink / raw)
To: lartc
[-- Attachment #1: Type: text/plain, Size: 4656 bytes --]
Sorry,I means that:
I configure My out interface bandwidth 10kbps.
tc qdisc del dev eth1 root
tc qdisc add dev eth1 root handle 30: htb
tc class add dev eth1 parent 30: classid 30:1 htb rate 10kbps ceil 10kbps
tc class add dev eth1 parent 30:1 classid 30:10 htb rate 5kbps ceil 5kbps
tc class add dev eth1 parent 30:10 classid 30:100 htb rate 2.5kbps ceil 5kbps
tc class add dev eth1 parent 30:100 classid 30:1000 htb rate 1.25kbps ceil 5kbps prio 1
tc qdisc add dev eth1 parent 30:1000 sfq
tc class add dev eth1 parent 30:100 classid 30:2000 htb rate 1.25kbps ceil 5kbps prio 2
tc qdisc add dev eth1 parent 30:2000 sfq
tc class add dev eth1 parent 30:10 classid 30:200 htb rate 2kbps ceil 5kbps
tc qdisc add dev eth1 parent 30:200 sfq
tc class add dev eth1 parent 30:1 classid 30:20 htb rate 5kbps ceil 10kbps
tc qdisc add dev eth1 parent 30:20 sfq
tc filter add dev eth1 parent 30: protocol ip prio 1 handle 8 fw classid 30:20
tc filter add dev eth1 parent 30: protocol ip prio 1 handle 9 fw classid 30:1000
tc filter add dev eth1 parent 30: protocol ip prio 1 handle 10 fw classid 30:2000
tc -s class ls dev eth1
class htb 30:1 root rate 80Kbit ceil 80Kbit burst 1701b cburst 1701b
Sent 3241503 bytes 55558 pkts (dropped 0, overlimits 0)
lended: 0 borrowed: 0 giants: 0
tokens: 132320 ctokens: 132320
class htb 30:10 parent 30:1 rate 40Kbit ceil 40Kbit burst 1650b cburst 1650b
Sent 3235253 bytes 55462 pkts (dropped 0, overlimits 0)
lended: 25964 borrowed: 0 giants: 0
tokens: 256479 ctokens: 256479
class htb 30:100 parent 30:10 rate 20Kbit ceil 40Kbit burst 1624b cburst 1650b
Sent 3235253 bytes 55462 pkts (dropped 0, overlimits 0)
lended: 12826 borrowed: 25964 giants: 0
tokens: 504639 ctokens: 256479
class htb 30:1000 parent 30:100 leaf 802f: prio 1 rate 10Kbit ceil 40Kbit burst 1611b cburst 1650b
Sent 3025299 bytes 52329 pkts (dropped 0, overlimits 0)
lended: 14206 borrowed: 38123 giants: 0
tokens: 1000960 ctokens: 256479
class htb 30:2000 parent 30:100 leaf 8030: prio 2 rate 10Kbit ceil 40Kbit burst 1611b cburst 1650b
Sent 209954 bytes 3133 pkts (dropped 0, overlimits 0)
lended: 2466 borrowed: 667 giants: 0
tokens: -317952 ctokens: 243679
class htb 30:200 parent 30:10 leaf 8031: prio 0 rate 16Kbit ceil 40Kbit burst 1619b cburst 1650b
Sent 0 bytes 0 pkts (dropped 0, overlimits 0)
lended: 0 borrowed: 0 giants: 0
tokens: 647999 ctokens: 264159
class htb 30:20 parent 30:1 leaf 8032: prio 0 rate 40Kbit ceil 80Kbit burst 1650b cburst 1701b
Sent 6250 bytes 96 pkts (dropped 0, overlimits 0)
lended: 96 borrowed: 0 giants: 0
tokens: 256479 ctokens: 132320
http,https traffic from 30:1000 and ftp,ftp-data traffic from 30:2000
I download kernel from www.kernel.org use NetAnts.I noted that rate 200kbps!!!!?
question :
1. I don't know why that rate of NetAnts(200kbps) > out bandwidth(10kbps).
2. I think it maybe dropped packets,but nothing to do .
3. tokens: -317952 ctokens: 243679 what's means about parameters?what's representation positive number or negative number?
"Martin A. Brown" <mabrown-lartc@securepipe.com> wrote: : tc class add dev eth1 parent 30:100 classid 30:1000 \
: htb rate 12800kbps ceil 51200kbps prio 1
: tc qdisc add dev eth1 parent 30:1000 sfq
Whoa!! Are you *sure* you mean 12800 kilobytes per second and 51200 kilo
bytes per second? Just double-checking.
This sort of number looks quite similar to what I call a 128k / 512k line.
I would specify these rates as follows:
128kbit and 512kbit
But maybe you really mean:
12800kbit and 51200kbit
Judging from your "tc -s" output, you have a large pipe to the 'net.
: How to do obtain below result:
: I read from www.docum.org have problem about parameter:
Which parameter are you asking about? You don't provide much information
to us about what your question or concern is.
Is quantum the problem? Or burst, cburst.
: Frist :
:
: The same story goes for ceil and cburst, you don't want the class to
: send more packets then it's ceil allows. So removing the cburst is a
: good choice for that case.
:
: Second:
:
: Packets that are sent when the class is allowed to send, are still
: matched against rate/ceil/burst/cburst. So a big quantum will not
: create bursts if you don't allow it with the burs/cburst parameters.
Help us understand what your question is, Liang. Thank you,
-Martin
--
Martin A. Brown --- SecurePipe, Inc. --- mabrown@securepipe.com
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
---------------------------------
Do You Yahoo!?
"用雅虎搜索,找到关于奥斯卡的一切"
[-- Attachment #2: Type: text/html, Size: 5443 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: [LARTC] htb parameter problem
2003-03-07 6:36 [LARTC] htb parameter problem liang jian
2003-03-07 6:55 ` Martin A. Brown
2003-03-07 8:53 ` liang jian
@ 2003-03-08 19:39 ` Stef Coene
2003-03-10 2:02 ` liang jian
` (5 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Stef Coene @ 2003-03-08 19:39 UTC (permalink / raw)
To: lartc
On Friday 07 March 2003 09:53, liang jian wrote:
> Sorry,I means that:
> I configure My out interface bandwidth 10kbps.
> tc qdisc del dev eth1 root
> tc qdisc add dev eth1 root handle 30: htb
> tc class add dev eth1 parent 30: classid 30:1 htb rate 10kbps ceil 10kbps
> tc class add dev eth1 parent 30:1 classid 30:10 htb rate 5kbps ceil 5kbps
> tc class add dev eth1 parent 30:10 classid 30:100 htb rate 2.5kbps ceil
> 5kbps tc class add dev eth1 parent 30:100 classid 30:1000 htb rate 1.25kbps
> ceil 5kbps prio 1 tc qdisc add dev eth1 parent 30:1000 sfq
> tc class add dev eth1 parent 30:100 classid 30:2000 htb rate 1.25kbps ceil
> 5kbps prio 2 tc qdisc add dev eth1 parent 30:2000 sfq
> tc class add dev eth1 parent 30:10 classid 30:200 htb rate 2kbps ceil 5kbps
> tc qdisc add dev eth1 parent 30:200 sfq
> tc class add dev eth1 parent 30:1 classid 30:20 htb rate 5kbps ceil 10kbps
> tc qdisc add dev eth1 parent 30:20 sfq
> tc filter add dev eth1 parent 30: protocol ip prio 1 handle 8 fw classid
> 30:20 tc filter add dev eth1 parent 30: protocol ip prio 1 handle 9 fw
> classid 30:1000 tc filter add dev eth1 parent 30: protocol ip prio 1
> handle 10 fw classid 30:2000
>
> tc -s class ls dev eth1
> class htb 30:1 root rate 80Kbit ceil 80Kbit burst 1701b cburst 1701b
> Sent 3241503 bytes 55558 pkts (dropped 0, overlimits 0)
> lended: 0 borrowed: 0 giants: 0
> tokens: 132320 ctokens: 132320
> class htb 30:10 parent 30:1 rate 40Kbit ceil 40Kbit burst 1650b cburst
> 1650b Sent 3235253 bytes 55462 pkts (dropped 0, overlimits 0)
> lended: 25964 borrowed: 0 giants: 0
> tokens: 256479 ctokens: 256479
> class htb 30:100 parent 30:10 rate 20Kbit ceil 40Kbit burst 1624b cburst
> 1650b Sent 3235253 bytes 55462 pkts (dropped 0, overlimits 0)
> lended: 12826 borrowed: 25964 giants: 0
> tokens: 504639 ctokens: 256479
> class htb 30:1000 parent 30:100 leaf 802f: prio 1 rate 10Kbit ceil 40Kbit
> burst 1611b cburst 1650b Sent 3025299 bytes 52329 pkts (dropped 0,
> overlimits 0)
> lended: 14206 borrowed: 38123 giants: 0
> tokens: 1000960 ctokens: 256479
> class htb 30:2000 parent 30:100 leaf 8030: prio 2 rate 10Kbit ceil 40Kbit
> burst 1611b cburst 1650b Sent 209954 bytes 3133 pkts (dropped 0, overlimits
> 0)
> lended: 2466 borrowed: 667 giants: 0
> tokens: -317952 ctokens: 243679
> class htb 30:200 parent 30:10 leaf 8031: prio 0 rate 16Kbit ceil 40Kbit
> burst 1619b cburst 1650b Sent 0 bytes 0 pkts (dropped 0, overlimits 0)
> lended: 0 borrowed: 0 giants: 0
> tokens: 647999 ctokens: 264159
> class htb 30:20 parent 30:1 leaf 8032: prio 0 rate 40Kbit ceil 80Kbit burst
> 1650b cburst 1701b Sent 6250 bytes 96 pkts (dropped 0, overlimits 0)
> lended: 96 borrowed: 0 giants: 0
> tokens: 256479 ctokens: 132320
>
> http,https traffic from 30:1000 and ftp,ftp-data traffic from 30:2000
> I download kernel from www.kernel.org use NetAnts.I noted that rate
> 200kbps!!!!? question :
> 1. I don't know why that rate of NetAnts(200kbps) > out bandwidth(10kbps).
Maybe it was locally cached ?
An other question, are you sure each packets ends in a class? I never see
your marking rules and you don't specified a default class.
> 2. I think it maybe dropped packets,but nothing to do .
> 3. tokens: -317952 ctokens: 243679 what's means about parameters?what's
> representation positive number or negative number?
Don't worry about these numbers :)
ctokens < 0 means the class sent more then the ceil because parent child
classes are asking too much bandwidth. Same for tokens and rate.
Stef
--
stef.coene@docum.org
"Using Linux as bandwidth manager"
http://www.docum.org/
#lartc @ irc.oftc.net
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
^ permalink raw reply [flat|nested] 10+ messages in thread* [LARTC] htb parameter problem
2003-03-07 6:36 [LARTC] htb parameter problem liang jian
` (2 preceding siblings ...)
2003-03-08 19:39 ` Stef Coene
@ 2003-03-10 2:02 ` liang jian
2003-03-10 13:01 ` Kertész Viktor
` (4 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: liang jian @ 2003-03-10 2:02 UTC (permalink / raw)
To: lartc
[-- Attachment #1: Type: text/plain, Size: 5946 bytes --]
>wrote by Stef Coene stef.coene@docum.org
>On Friday 07 March 2003 09:53, liang jian wrote:
>> Sorry,I means that:
> >I configure My out interface bandwidth 10kbps.
> >tc qdisc del dev eth1 root
> >tc qdisc add dev eth1 root handle 30: htb
> >tc class add dev eth1 parent 30: classid 30:1 htb rate 10kbps ceil 10kbps
> >tc class add dev eth1 parent 30:1 classid 30:10 htb rate 5kbps ceil 5kbps
> >tc class add dev eth1 parent 30:10 classid 30:100 htb rate 2.5kbps ceil
> >5kbps tc class add dev eth1 parent 30:100 classid 30:1000 htb rate 1.25kbps
> >ceil 5kbps prio 1 tc qdisc add dev eth1 parent 30:1000 sfq
> >tc class add dev eth1 parent 30:100 classid 30:2000 htb rate 1.25kbps ceil
> >5kbps prio 2 tc qdisc add dev eth1 parent 30:2000 sfq
> >tc class add dev eth1 parent 30:10 classid 30:200 htb rate 2kbps ceil 5kbps
> >tc qdisc add dev eth1 parent 30:200 sfq
> >tc class add dev eth1 parent 30:1 classid 30:20 htb rate 5kbps ceil 10kbps
> >tc qdisc add dev eth1 parent 30:20 sfq
> >tc filter add dev eth1 parent 30: protocol ip prio 1 handle 8 fw classid
> >30:20 tc filter add dev eth1 parent 30: protocol ip prio 1 handle 9 fw
> >classid 30:1000 tc filter add dev eth1 parent 30: protocol ip prio 1
> >handle 10 fw classid 30:2000
>>
> >tc -s class ls dev eth1
> >class htb 30:1 root rate 80Kbit ceil 80Kbit burst 1701b cburst 1701b
> >Sent 3241503 bytes 55558 pkts (dropped 0, overlimits 0)
> >lended: 0 borrowed: 0 giants: 0
> >tokens: 132320 ctokens: 132320
> >class htb 30:10 parent 30:1 rate 40Kbit ceil 40Kbit burst 1650b cburst
> >1650b Sent 3235253 bytes 55462 pkts (dropped 0, overlimits 0)
> >lended: 25964 borrowed: 0 giants: 0
> >tokens: 256479 ctokens: 256479
> >class htb 30:100 parent 30:10 rate 20Kbit ceil 40Kbit burst 1624b cburst
> >1650b Sent 3235253 bytes 55462 pkts (dropped 0, overlimits 0)
> >lended: 12826 borrowed: 25964 giants: 0
> >tokens: 504639 ctokens: 256479
> >class htb 30:1000 parent 30:100 leaf 802f: prio 1 rate 10Kbit ceil 40Kbit
> >burst 1611b cburst 1650b Sent 3025299 bytes 52329 pkts (dropped 0,
> >overlimits 0)
> >lended: 14206 borrowed: 38123 giants: 0
> >tokens: 1000960 ctokens: 256479
> >class htb 30:2000 parent 30:100 leaf 8030: prio 2 rate 10Kbit ceil 40Kbit
> >burst 1611b cburst 1650b Sent 209954 bytes 3133 pkts (dropped 0, overlimits
> >0)
> > lended: 2466 borrowed: 667 giants: 0
> >tokens: -317952 ctokens: 243679
> >class htb 30:200 parent 30:10 leaf 8031: prio 0 rate 16Kbit ceil 40Kbit
> >burst 1619b cburst 1650b Sent 0 bytes 0 pkts (dropped 0, overlimits 0)
> >lended: 0 borrowed: 0 giants: 0
> >tokens: 647999 ctokens: 264159
> >class htb 30:20 parent 30:1 leaf 8032: prio 0 rate 40Kbit ceil 80Kbit burst
> >1650b cburst 1701b Sent 6250 bytes 96 pkts (dropped 0, overlimits 0)
> >lended: 96 borrowed: 0 giants: 0
> >tokens: 256479 ctokens: 132320
>>
> >http,https traffic from 30:1000 and ftp,ftp-data traffic from 30:2000
> >I download kernel from www.kernel.org use NetAnts.I noted that rate
> >200kbps!!!!? question :
> >1. I don't know why that rate of NetAnts(200kbps) > out bandwidth(10kbps).
>Maybe it was locally cached ?
>An other question, are you sure each packets ends in a class?
I don't know about it.why do that? How to it?
> I never see your marking rules
Below My filter and iptables rules
tc filter add dev eth1 parent 30: protocol ip prio 1 handle 8 fw classid 30:20
tc filter add dev eth1 parent 30: protocol ip prio 1 handle 9 fw classid 30:1000
tc filter add dev eth1 parent 30: protocol ip prio 1 handle 10 fw classid 30:2000
iptables -t mangle -A FORWARD -p tcp -o eth0 -s 0/0 --dport ftp -d 0/0 -j MARK --set-mark 2
iptables -t mangle -A PREROUTING -p tcp -i eth0 -s 0/0 --dport ftp -d 0/0 -j MARK --set-mark 2
iptables -t mangle -A FORWARD -p tcp -o eth0 -s 0/0 --dport ftp-data -d 0/0 -j MARK --set-mark 7
iptables -t mangle -A PREROUTING -p tcp -i eth0 -s 0/0 --dport ftp-data -d 0/0 -j MARK --set-mark 7
iptables -t mangle -A FORWARD -p tcp -o eth0 -s 0/0 --dport http -d 0/0 -j MARK --set-mark 5
iptables -t mangle -A PREROUTING -p tcp -i eth0 -s 0/0 --dport http -d 0/0 -j MARK --set-mark 5
iptables -t mangle -A FORWARD -p tcp -o eth0 -s 0/0 --dport https -d 0/0 -j MARK --set-mark 5
iptables -t mangle -A PREROUTING -p tcp -i eth0 -s 0/0 --dport https -d 0/0 -j MARK --set-mark 5
iptables -t mangle -A FORWARD -p tcp -o eth1 -s 0/0 --dport ftp -d 0/0 -j MARK --set-mark 8
iptables -t mangle -A PREROUTING -p tcp -i eth1 -s 0/0 --dport ftp -d 0/0 -j MARK --set-mark 8
iptables -t mangle -A FORWARD -p tcp -o eth1 -s 0/0 --dport ftp-data -d 0/0 -j MARK --set-mark 10
iptables -t mangle -A PREROUTING -p tcp -i eth1 -s 0/0 --dport ftp-data -d 0/0 -j MARK --set-mark 10
iptables -t mangle -A FORWARD -p tcp -o eth1 -s 0/0 --dport http -d 0/0 -j MARK --set-mark 9
iptables -t mangle -A PREROUTING -p tcp -i eth1 -s 0/0 --dport http -d 0/0 -j MARK --set-mark 9
iptables -t mangle -A FORWARD -p tcp -o eth1 -s 0/0 --dport https -d 0/0 -j MARK --set-mark 9
iptables -t mangle -A PREROUTING -p tcp -i eth1 -s 0/0 --dport https -d 0/0 -j MARK --set-mark 9
> and you don't specified a default class.
I don't know about it and why do that ? how to do it?
>> 2. I think it maybe dropped packets,but nothing to do .
> >3. tokens: -317952 ctokens: 243679 what's means about parameters?what's
> >representation positive number or negative number?
>Don't worry about these numbers :)
>ctokens < 0 means the class sent more then the ceil because parent child
>classes are asking too much bandwidth. Same for tokens and rate.
If I want to fixate every class bandwidth. not lended and not borrow .How to do it.
cburst play tricks??
On www.docum.org's FAQ have :
The same story goes for ceil and cburst, you don't want the class to send more packets then it's ceil allows. So removing the cburst is a good choice for that case.
>Stef
>--
---------------------------------
Do You Yahoo!?
"美女们的秘密武器!"
[-- Attachment #2: Type: text/html, Size: 8131 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: [LARTC] htb parameter problem
2003-03-07 6:36 [LARTC] htb parameter problem liang jian
` (3 preceding siblings ...)
2003-03-10 2:02 ` liang jian
@ 2003-03-10 13:01 ` Kertész Viktor
2003-03-10 17:51 ` Stef Coene
` (3 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Kertész Viktor @ 2003-03-10 13:01 UTC (permalink / raw)
To: lartc
Hi,
>
> iptables -t mangle -A FORWARD -p tcp -o eth0 -s 0/0 --dport ftp -d 0/0 -j MARK --set-mark 2
> iptables -t mangle -A PREROUTING -p tcp -i eth0 -s 0/0 --dport ftp -d 0/0 -j MARK --set-mark 2
> iptables -t mangle -A FORWARD -p tcp -o eth0 -s 0/0 --dport ftp-data -d 0/0 -j MARK --set-mark 7
> iptables -t mangle -A PREROUTING -p tcp -i eth0 -s 0/0 --dport ftp-data -d 0/0 -j MARK --set-mark 7
> iptables -t mangle -A FORWARD -p tcp -o eth0 -s 0/0 --dport http -d 0/0 -j MARK --set-mark 5
instead of --dport ftp-data/ftp use -m helper --helper "ftp". Match for
port does not work because of the nature of ftp. (passive mode) This can
be tricky.
Viktor
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: [LARTC] htb parameter problem
2003-03-07 6:36 [LARTC] htb parameter problem liang jian
` (4 preceding siblings ...)
2003-03-10 13:01 ` Kertész Viktor
@ 2003-03-10 17:51 ` Stef Coene
2003-03-12 12:48 ` liang jian
` (2 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: Stef Coene @ 2003-03-10 17:51 UTC (permalink / raw)
To: lartc
> I don't know about it.why do that? How to it?
By specifying a default class (see comments below) or a "catch all rules". I
see you use the fw rule. If you add
iptables -t mangle -A FORWARD -o eth0 -s 0/0 -j MARK --set-mark 1
iptables -t mangle -A PREROUTING -i eth0 -s 0/0 -j MARK --set-mark 1
as the first iptables rules, all packets are marked (you can overwrite this
mark with the other iptalbes rules). And if you add an extra filter rule
that puts the packets marked with 1 in a class, you have a "catch all rule".
You can also add a "catch all" u32 filter rule as the last filter.
> > and you don't specified a default class.
> I don't know about it and why do that ? how to do it?
If you add the htb qdisc, you can specify a default class. Like
tc qdisc add dev eth1 root handle 10: htb default 20
So 10:20 is the default class. If a packet is not matched by any filter, it
ends in the default class. It's also best to specify a default class so you
know all the packets are ending in a class.
> >Don't worry about these numbers :)
> >ctokens < 0 means the class sent more then the ceil because parent child
> >classes are asking too much bandwidth. Same for tokens and rate.
>
> If I want to fixate every class bandwidth. not lended and not borrow .How
> to do it.
By not specifying a ceil parameter. So rate = ceil. Or of course you can add
a ceil parameter like
tc class add dev eth0 parent 10:1 classid 10:10 htb rate 3mbit ceil 3mbit
> cburst play tricks??
> On www.docum.org's FAQ have :
>
> The same story goes for ceil and cburst, you don't want the class to send
> more packets then it's ceil allows. So removing the cburst is a good choice
> for that case.
Cburst and burst is for something else. That can be used if you want a class
to be able to "break" the rate and ceil limitations. If you want the ceil
parameter to be respected very strictly so the class never can send more then
it's ceil, you have to remove the cburst parameter if you add a class so htb
can calculate the smalles one for you.
Stef
--
stef.coene@docum.org
"Using Linux as bandwidth manager"
http://www.docum.org/
#lartc @ irc.oftc.net
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: [LARTC] htb parameter problem
2003-03-07 6:36 [LARTC] htb parameter problem liang jian
` (5 preceding siblings ...)
2003-03-10 17:51 ` Stef Coene
@ 2003-03-12 12:48 ` liang jian
2003-03-12 20:48 ` Stef Coene
2003-03-13 2:31 ` liang jian
8 siblings, 0 replies; 10+ messages in thread
From: liang jian @ 2003-03-12 12:48 UTC (permalink / raw)
To: lartc
[-- Attachment #1: Type: text/plain, Size: 538 bytes --]
My tc commands:
tc class add dev eth1 parent 30: classid 30:1 htb rate 10kbps ceil 10kbps
tc class add dev eth1 parent 30:1 classid 30:10 htb rate 5kbps ceil 5kbps
why it have the cburst parameter ?
# tc -s class ls dev eth1
class htb 30:1 root rate 80Kbit ceil 80Kbit burst 1701b cburst 1701b
Sent 3241503 bytes 55558 pkts (dropped 0, overlimits 0)
lended: 0 borrowed: 0 giants: 0
tokens: 132320 ctokens: 132320
My tc command howto drop cburst parameter?
---------------------------------
Do You Yahoo!?
"美女们的秘密武器!"
[-- Attachment #2: Type: text/html, Size: 765 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: [LARTC] htb parameter problem
2003-03-07 6:36 [LARTC] htb parameter problem liang jian
` (6 preceding siblings ...)
2003-03-12 12:48 ` liang jian
@ 2003-03-12 20:48 ` Stef Coene
2003-03-13 2:31 ` liang jian
8 siblings, 0 replies; 10+ messages in thread
From: Stef Coene @ 2003-03-12 20:48 UTC (permalink / raw)
To: lartc
On Wednesday 12 March 2003 13:48, liang jian wrote:
> My tc commands:
> tc class add dev eth1 parent 30: classid 30:1 htb rate 10kbps ceil 10kbps
> tc class add dev eth1 parent 30:1 classid 30:10 htb rate 5kbps ceil 5kbps
>
>
> why it have the cburst parameter ?
> # tc -s class ls dev eth1
> class htb 30:1 root rate 80Kbit ceil 80Kbit burst 1701b cburst 1701b
> Sent 3241503 bytes 55558 pkts (dropped 0, overlimits 0)
> lended: 0 borrowed: 0 giants: 0
> tokens: 132320 ctokens: 132320
> My tc command howto drop cburst parameter?
You need a minimal cburst parameter. If you don't specify one, htb will
calculated the smalles possible one for you. Same for burst.
Stef
--
stef.coene@docum.org
"Using Linux as bandwidth manager"
http://www.docum.org/
#lartc @ irc.oftc.net
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
^ permalink raw reply [flat|nested] 10+ messages in thread* Re: [LARTC] htb parameter problem
2003-03-07 6:36 [LARTC] htb parameter problem liang jian
` (7 preceding siblings ...)
2003-03-12 20:48 ` Stef Coene
@ 2003-03-13 2:31 ` liang jian
8 siblings, 0 replies; 10+ messages in thread
From: liang jian @ 2003-03-13 2:31 UTC (permalink / raw)
To: lartc
[-- Attachment #1: Type: text/plain, Size: 1069 bytes --]
>> My tc commands:
>> tc class add dev eth1 parent 30: classid 30:1 htb rate 10kbps ceil 10kbps
>> tc class add dev eth1 parent 30:1 classid 30:10 htb rate 5kbps ceil 5kbps
>>
>>
>> why it have the cburst parameter ?
>> # tc -s class ls dev eth1
>> class htb 30:1 root rate 80Kbit ceil 80Kbit burst 1701b cburst 1701b
>> Sent 3241503 bytes 55558 pkts (dropped 0, overlimits 0)
>> lended: 0 borrowed: 0 giants: 0
>> tokens: 132320 ctokens: 132320
>> My tc command howto drop cburst parameter?
>You need a minimal cburst parameter. If you don't specify one, htb will
calculated the smalles possible one for you. Same for burst.
>Stef
>--
>stef.coene@docum.org
>"Using Linux as bandwidth manager"
>http://www.docum.org/
>#lartc @ irc.oftc.net
>_______________________________________________
>LARTC mailing list / LARTC@mailman.ds9a.nl
>http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
lartc's group help me ! it let's me understand a lot of tc .
Thank your very much!
---------------------------------
Do You Yahoo!?
"美女们的秘密武器!"
[-- Attachment #2: Type: text/html, Size: 1427 bytes --]
^ permalink raw reply [flat|nested] 10+ messages in thread