From: "Santiago" Date: Wed, 29 Aug 2007 21:06:58 +0000 Subject: Re: [LARTC] How tho share varible bandwidth with weighted round robin Message-Id: <20070829204633.M41909@elportal.net.ec> MIME-Version: 1 Content-Type: multipart/mixed; boundary="===============0330467816==" List-Id: References: <20070829160044.M8350@elportal.net.ec> In-Reply-To: <20070829160044.M8350@elportal.net.ec> To: lartc@vger.kernel.org This is a multi-part message in MIME format. --===============0330467816== Content-Type: multipart/alternative; boundary="----=OPENWEBMAIL_ATT_0.336278503834368" This is a multi-part message in MIME format. ------=OPENWEBMAIL_ATT_0.336278503834368 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable I thought the same thing a year ago. =A0You set an htb class bigger than Vm= ax in the output ethernet, the you can attach =A0esfq or WRR (sfq only work= s with conecctions and I need to work with destination ip addresses). But i= t never works. =A0 Now I understand that if you set the class bigger than Vmax. The queue is a= lways empty, and the qdisc is never used. =A0You can adjust the htb class s= maller than Vmin. Then you have a no-empty queue and the qdisc should work.= But you are going to lose bandwidth if your ISP in sending to you a speed = bigger than Vmin. =A0 Internet (Vmax-Vmin)------>Ethernet input Linux box--------->Ethernet outpu= t linux box----------->Some lan users The idea is all lan users get the same=A0bandwidth in any moment. Nobody ca= n get more bandwidth than the others. Any other idea? Santiago On Wed, 29 Aug 2007 20:12:09 +0200, Javier Ors wrote > >=20 > As far as I undestand, at least sfq should work without knowing the actua= l bandwith (you don't need to specify it in the qdisc creation). The proble= m with it is that it only works in the bottleneck of the network, where the= queues form, which is usually the machine which has the hardware that make= s the connection to the Internet. For example in this configuration...=20 >=20 > Internet <--- cable/dsl/etc. ---> Router/Modem <---ethernet---> Firewall = <---ethernet---->LAN >=20 > shaping outgoing traffic (traffic to the internet) with only sfq, esfq, p= rio, etc... will be useless if it is done in the firewall, becouse the queu= es will form in the router. It could be done in the same router if it has t= he capability (for example, it runs Linux inside and it is accessible by ss= h or telnet). I haven't tried WRR but the same should be applied.=20 >=20 > Theoretically, at least as I see it, HTB could also be used without knowi= ng the actual speed in the bottleneck, you just should set the root class t= o a speed higher than Vmax and adjust the rates of the leaf classes to the = desired ratios, or playing with the quantums so that it behaves like a WRR = or DRR (which is that it uses internally when the classes are borrowing). B= ut I have made many attempts in this sense and all of them have been unsucc= essful, don't know why.=20 >=20 > For incoming traffic it is another story, it can be done in the firewall,= but it is a little trickier. >=20 > Even more theoretically, outgoing shaping maybe could be done also in the= firewall if the router supports ECN, so that the queues could be formed in= the firewall using this information without nedding to reduce the bandwith= , but this is just a mental experiment which still have pending to brought = to practice, so don't pay much attention to this...=20 >=20 > --=20 > Este mensaje ha sido analizado por MailScanner=20 > en busca de virus y otros contenidos peligrosos,=20 > y se considera que est=E1 limpio.=20 > MailScanner agradece a transtec Computers por su apoyo. The original question: =A0I have this problem: I have an Internet line input with variable speed. I have a max speed and a= =20 min speed: Vmax and Vmin. The speed is always changing between Vmax and Vmin. I want to share the=20 actual bandwidth (you don't not how much, you only know the speed is betwee= n=20 Vmax and Vmin) for N clients. The bandwidth should be shared so nobody can = get more bandwidth than the others. There is some queue disciplines like esfq and WRR (w. But theses ones only = work=20 if you know the actual bandwidth. HTB works only width fixed bandwidth too. I have studied all shaping and queue disciplines in linux, and I don't have= =20 a real solution yet. Do you have any idea? Santiago --=20 Open WebMail Project (http://openwebmail.org) There is some queue disciplines like esfq and WRR (w. But theses ones only = > work if you know the actual bandwidth. =20 --=20 Este mensaje ha sido analizado por MailScanner en busca de virus y otros contenidos peligrosos, y se considera que est=E1 limpio. MailScanner agradece a transtec Computers por su apoyo. ------=OPENWEBMAIL_ATT_0.336278503834368 Content-Type: text/html; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable =0A= =0A= = =0A= =0A= =0A= =0A= =0A=

I thought the same thing a year ago. =A0You set an htb class bigger than Vmax in the output ethernet, = the you can attach =A0esfq or WRR = (sfq only works with conecctions and I need to work with destination ip add= resses). But it never works.=0A=

=0A= =0A=

=0A=

=A0

=0A=

=0A= =0A=

Now I understand that if you set the class bigger than Vmax. The que= ue is always empty, and the qdisc is never used. =A0You can adjust the htb class smaller than Vmin. Then you = have a no-empty queue and the qdisc should work. But you are going to lose = bandwidth if your ISP in sending to you a speed bigger than Vmin.=0A=

=0A= =0A=

=0A=

=A0

=0A=

=0A= =0A=

=0A=

Internet (Vmax-Vmin)------>= Ethernet input Linux box--------->Ethernet output linux box-----------&g= t;Some lan users

=0A=

=0A= =0A=

=0A=

=0A=

=0A= =0A=

=0A=

The idea is all lan users get = the same=A0bandwidth in any moment. Nobody can get more bandwidth than the = others.

=0A=

=0A= =0A=

=0A=

=0A=

=0A= =0A=

Any other idea?=0A=

=0A= =0A=

Santiago

=0A= =0A=

On Wed, 29 Aug 2007 20:12:09 +0200, Javier Ors wrote= =0A=
> =0A=

=0A=
>=20=0A=
> As far as I undestand, at least sfq should work without knowing = the actual bandwith (you don't need to specify it in the qdisc creation). T= he problem with it is that it only works in the bottleneck of the network, = where the queues form, which is usually the machine which has the hardware = that makes the connection to the Internet. For example in this configuratio= n...=20=0A=
>=20=0A=
> Internet <--- cable/dsl/etc. ---> Router/Modem <---ethe= rnet---> Firewall <---ethernet---->LAN=0A=
>=20=0A=
> shaping outgoing traffic (traffic to the internet) with only sfq= , esfq, prio, etc... will be useless if it is done in the firewall, becouse= the queues will form in the router. It could be done in the same router if= it has the capability (for example, it runs Linux inside and it is accessi= ble by ssh or telnet). I haven't tried WRR but the same should be applied.= =20=0A=
>=20=0A=
> Theoretically, at least as I see it, HTB could also be used with= out knowing the actual speed in the bottleneck, you just should set the roo= t class to a speed higher than Vmax and adjust the rates of the leaf classe= s to the desired ratios, or playing with the quantums so that it behaves li= ke a WRR or DRR (which is that it uses internally when the classes are borr= owing). But I have made many attempts in this sense and all of them have be= en unsuccessful, don't know why.=20=0A=
>=20=0A=
> For incoming traffic it is another story, it can be done in the = firewall, but it is a little trickier.=0A=
>=20=0A=
> Even more theoretically, outgoing shaping maybe could be done al= so in the firewall if the router supports ECN, so that the queues could be = formed in the firewall using this information without nedding to reduce the= bandwith, but this is just a mental experiment which still have pending to= brought to practice, so don't pay much attention to this...=20=0A=
>=20=0A=
> --=20=0A=
> Este mensaje ha sido analizado por =20=0A=
> en busca de virus y otros contenidos peligrosos,=20=0A=
> y se considera que est=E1 limpio.=20=0A=
> MailScanner agradece a
p= or su apoyo.=20=0A=

=0A= =0A=

=0A=

The original question:

=0A= =0A=

=A0I have this problem:=20=0A=
=0A=
I have an Internet line input with variable speed. I have a max speed= and a=20=0A=
min speed: Vmax and Vmin.=20=0A=
=0A=
The speed is always changing between Vmax and Vmin. I want to share t= he=20=0A=
actual bandwidth (you don't not how much, you only know the speed is = between=20=0A=
Vmax and Vmin) for N clients. The bandwidth should be shared so nobod= y can=20=0A=
get more bandwidth than the others.=20=0A=
=0A=
There is some queue disciplines like esfq and WRR (w. But theses ones= only=20=0A=
work=20=0A=
if you know the actual bandwidth. HTB works only width fixed bandwidt= h too.=20=0A=
=0A=
I have studied all shaping and queue disciplines in linux, and I don'= t have=20=0A=
a real solution yet.=20=0A=
=0A=
Do you have any idea?=20=0A=
=0A=
Santiago
=0A=
=0A=
--=20=0A=
Open WebMail Project (
http://openwebmail.org)=20=0A=
=0A=

=0A=

=0A=
There is some queue = disciplines like esfq and WRR (w. But theses ones only=20=0A=
> work if you know the actual bandwidth.
=0A= =0A=
--=20=0A=
Este mensaje ha sido analizado por=20=0A= MailScanner=0A=
en busca de virus y otros contenidos peligrosos,=0A=
y se considera que está limpio.=0A=
MailScanner agradece a transte= c Computers por su apoyo.=0A= =0A= =0A= ------=OPENWEBMAIL_ATT_0.336278503834368-- --===============0330467816== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ LARTC mailing list LARTC@mailman.ds9a.nl http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc --===============0330467816==--