I am using tbf to do bandwidth limitation. i found that when i start passing traffic there is a burst and then the rate goes down to what is configured. is this a known issue or do i need to change some parameters? thanks. --------------------------------- Do you Yahoo!? Read only the mail you want - Yahoo! Mail SpamGuard. _______________________________________________ LARTC mailing list LARTC@mailman.ds9a.nl http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc
Greetings, : I am using tbf to do bandwidth limitation. i found that when i : start passing traffic there is a burst and then the rate goes : down to what is configured. is this a known issue or do i need to : change some parameters? The behaviour you have described is exactly the theoretical goal of a token bucket filter, and also the practical behaviour of the TBF queueing discipline. In other words, congratulations, you are using a TBF! You probably wish to tweak parameters. -Martin -- Martin A. Brown --- Wonderfrog Enterprises --- martin@wonderfrog.net
I´ve read all the definitions of burst and cburst and I´ve tried playing with the parameters and graphing the output of the filter to see its effects, but STILL I can´t figure out how the parameters work exactly. ¿Could anyone give a better explanation than the manpage?
Hello, : I´ve read all the definitions of burst and cburst and I´ve tried : playing with the parameters and graphing the output of the filter : to see its effects, but STILL I can´t figure out how the : parameters work exactly. : : Could anyone give a better explanation than the manpage? Have you tried Stef''s site? He has a good page [0] that talks about the various tests he did while experimenting with HTB burst and cburst parameters? Some time ago, I took a stab at creating a visual representation [1] of a hypothetical HTB configuration [2]. In order to understand when cburst is used, look for the diamond-shaped boxes in the diagram which talk about tokens and ctokens. Every HTB class has two buckets. rate bucket is of burst size, traffic uses tokens ceil bucket is of cburst size, traffic uses ctokens My diagram may give you the framework to understand exactly how they are used if it''s still unclear to you, but Stef''s site will give you much better detail on the results of using burst and cburst. Of the scenarios he describes, I like the results of Test 7 the best. The only guideline that struck me after reading his results was to prefer burst and cburst usage on parent classes. Good luck, -Martin [0] http://www.docum.org/docum.org/tests/htb/burst/ [1] http://linux-ip.net/traffic-control/htb-class.png [2] http://linux-ip.net/traffic-control/diagram.html -- Martin A. Brown --- Wonderfrog Enterprises --- martin@wonderfrog.net _______________________________________________ LARTC mailing list LARTC@mailman.ds9a.nl http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc
Ok, that´s great. I have a much better idea now. However I have a doubt on [1]. When packets arrive to an HTB filter, it first checks to see if there are ctokens available. How come if there are, it then checks for tokens instead of just dequeuing at full speed. And if there are none: shouldn´t it THEN check for tokens instead of discarding right away? Also, could you give me an advice or reference on the following? I need a child class to allow passage to a video stream that I KNOW has mean X kbps and seldom peaks of Y kbps and T seconds. Would the best way be to just configure mean=X, ceil=Y? Or should I configure mean=ceil=X and calculate a cburst that´ll allow passage of the peaks? Or maybe a third option. ----- Original Message ----- From: "Martin A. Brown" <mabrown-lartc@securepipe.com> To: "VideoIP" <videoip@gmail.com> Cc: "lartc" <lartc@mailman.ds9a.nl> Sent: Wednesday, July 13, 2005 2:14 AM Subject: Re: [LARTC] HTB: ¿how do burst/cburst work exactly? Hello, : I´ve read all the definitions of burst and cburst and I´ve tried : playing with the parameters and graphing the output of the filter : to see its effects, but STILL I can´t figure out how the : parameters work exactly. : : Could anyone give a better explanation than the manpage? Have you tried Stef''s site? He has a good page [0] that talks about the various tests he did while experimenting with HTB burst and cburst parameters? Some time ago, I took a stab at creating a visual representation [1] of a hypothetical HTB configuration [2]. In order to understand when cburst is used, look for the diamond-shaped boxes in the diagram which talk about tokens and ctokens. Every HTB class has two buckets. rate bucket is of burst size, traffic uses tokens ceil bucket is of cburst size, traffic uses ctokens My diagram may give you the framework to understand exactly how they are used if it''s still unclear to you, but Stef''s site will give you much better detail on the results of using burst and cburst. Of the scenarios he describes, I like the results of Test 7 the best. The only guideline that struck me after reading his results was to prefer burst and cburst usage on parent classes. Good luck, -Martin [0] http://www.docum.org/docum.org/tests/htb/burst/ [1] http://linux-ip.net/traffic-control/htb-class.png [2] http://linux-ip.net/traffic-control/diagram.html -- Martin A. Brown --- Wonderfrog Enterprises --- martin@wonderfrog.net
: However I have a doubt on [1]. When packets arrive to an HTB : filter, it first checks to see if there are ctokens available. : How come if there are, it then checks for tokens instead of just : dequeuing at full speed. And if there are none: shouldn´t it THEN : check for tokens instead of discarding right away? I would like to quibble about terminology here. A filter selects a destination class (which contains a qdisc). Filters have absolutely nothing to do with tokens. Once a packet has been filtered, it enters its destination class. Roughly speaking, the class does the following: 1. check to see if there are tokens available && dequeue 2. check to see if there are ctokens available && dequeue 3. wait until tokens become available && goto 2 (1?) Once a packet is in an HTB class, the packet will not get discarded by the class until the class itself has a tremendous backlog and needs to drop the packet. An HTB class will delay the transmission of the packet until tokens are available. This is the core feature which provides the shaping capability. : Also, could you give me an advice or reference on the following? : I need a child class to allow passage to a video stream that I : KNOW has mean X kbps and seldom peaks of Y kbps and T seconds. : Would the best way be to just configure mean=X, ceil=Y? Or should : I configure mean=ceil=X and calculate a cburst that´ll allow : passage of the peaks? Or maybe a third option. I cannot recommend an optimal calculation method, though I would start with X kbps as the rate and Y kbps * T as the burst. After that, I''d increase rate and decrease burst until there was no choppiness in the transmitted video stream. Good luck, -Martin : ----- Original Message ----- From: "Martin A. Brown" : <mabrown-lartc@securepipe.com> : To: "VideoIP" <videoip@gmail.com> : Cc: "lartc" <lartc@mailman.ds9a.nl> : Sent: Wednesday, July 13, 2005 2:14 AM : Subject: Re: [LARTC] HTB: ¿how do burst/cburst work exactly? : : : : Hello, : : : I´ve read all the definitions of burst and cburst and I´ve tried : : playing with the parameters and graphing the output of the filter : : to see its effects, but STILL I can´t figure out how the : : parameters work exactly. : : : : Could anyone give a better explanation than the manpage? : : Have you tried Stef''s site? He has a good page [0] that talks about : the various tests he did while experimenting with HTB burst and : cburst parameters? : : Some time ago, I took a stab at creating a visual representation [1] : of a hypothetical HTB configuration [2]. In order to understand : when cburst is used, look for the diamond-shaped boxes in the : diagram which talk about tokens and ctokens. : : Every HTB class has two buckets. : : rate bucket is of burst size, traffic uses tokens : ceil bucket is of cburst size, traffic uses ctokens : : My diagram may give you the framework to understand exactly how they : are used if it''s still unclear to you, but Stef''s site will give you : much better detail on the results of using burst and cburst. Of the : scenarios he describes, I like the results of Test 7 the best. The : only guideline that struck me after reading his results was to : prefer burst and cburst usage on parent classes. : : Good luck, : : -Martin : : [0] http://www.docum.org/docum.org/tests/htb/burst/ : [1] http://linux-ip.net/traffic-control/htb-class.png : [2] http://linux-ip.net/traffic-control/diagram.html : : -- Martin A. Brown --- Wonderfrog Enterprises --- martin@wonderfrog.net _______________________________________________ LARTC mailing list LARTC@mailman.ds9a.nl http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc
: : Also, could you give me an advice or reference on the following? : : I need a child class to allow passage to a video stream that I : : KNOW has mean X kbps and seldom peaks of Y kbps and T seconds. : : Would the best way be to just configure mean=X, ceil=Y? Or should : : I configure mean=ceil=X and calculate a cburst that´ll allow : : passage of the peaks? Or maybe a third option. : : I cannot recommend an optimal calculation method, though I would : start with X kbps as the rate and Y kbps * T as the burst. After : that, I''d increase rate and decrease burst until there was no : choppiness in the transmitted video stream. Would in that scenario ceil=rate or ceil=Y kbps? It seems to me that if ceil=rate, then there´s no use in having a burst bucket, or is there? Thanks again, Florencio