All of lore.kernel.org
 help / color / mirror / Atom feed
* [LARTC] Lots amounts of classes to solve the DAP problem
@ 2003-04-22 18:10 GoMi
  2003-04-22 18:52 ` Stef Coene
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: GoMi @ 2003-04-22 18:10 UTC (permalink / raw)
  To: lartc

 
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Stef, remember the problem about DAP users? i have written a little scrip to create 255 classes each for an ip of my segment, what do you think, am i mistaken anywhere?
I am not sure i am getting the concept right. The idea is 
Total BW is lets say 255kbit

                   root 1:0

User 192.168.1.1:
                         |
                        1:1 2kbit ceil 255kbit
                        / \  
                       /   \
 1kbit ceil 127kbit   1:2  1:4 1kbit ceil 128kbit
                       |    |
               pfifo  1:3  1:5 sfq

User 192.168.1.2
                         |
                        1:6 2kbit ceil 255kbit
                        / \  
                       /   \
 1kbit ceil 127kbit   1:7  1:8 1kbit ceil 128kbit
                       |    |
               pfifo  1:9  1:10 sfq                       

And soo on 255 times...

I now the rate of the classes add up to be more than the total BW but since i am doing that for 2 ADSL working with multipath (loadbalanding) routing, i think there will never be all users using one interface. Dont know if my assumption is right..

To end up i have to set up a hashing table to create all the filters. The script to create the structure is the one on the bottom. What do you think? Am i going in the right direction or did i just completly missed what you were having in mind..? ( I have not set up the hashing table for filters yet)

#!/bin/bash
UPLINK00
DEV=eth0

IP=""

for ((a=1;a<255;a++))
do
 IP=$IP" "$a
done


b=1

for a in $IP
do
 let "c=b"

   tc class add dev $DEV parent 1: classid 1:$b htb rate 2kbit ceil 300kbit
 let "b=b+1"

   tc class add dev $DEV parent 1:${c} classid 1:${b} htb rate 1kbit ceil 150kbit
 let "c=b"
 let "b=b+1"

   tc qdisc add dev $DEV parent 1:${c} handle ${b}: pfifo
 let "b=b+1"
 let "c=c-1"

   tc class add dev $DEV parent 1:${c} classid 1:${b} htb rate 1kbit ceil 150kbit
 let "c=b"
 let "b=b+1"

  tc qdisc add dev $DEV parent 1:${c} handle ${b}: sfq perturb 10
 let "b=b+1"

done

-----BEGIN PGP SIGNATURE-----
Version: PGP 8.0

iQA/AwUBPqWFe37diNnrrZKsEQLqHACgyyMjyFuClTgT8CZFZRUF++sFHRYAoLjA
HOWpYCLIrIa0rW32Cjh4P6bd
äFN
-----END PGP SIGNATURE-----
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2003-04-26  8:01 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-04-22 18:10 [LARTC] Lots amounts of classes to solve the DAP problem GoMi
2003-04-22 18:52 ` Stef Coene
2003-04-22 18:58 ` GoMi
2003-04-22 19:06 ` Stef Coene
2003-04-23 12:45 ` GoMi
2003-04-23 20:28 ` Stef Coene
2003-04-23 21:05 ` GoMi
2003-04-24 14:12 ` GoMi
2003-04-25 20:53 ` Stef Coene
2003-04-26  3:39 ` Rio Martin.
2003-04-26  4:50 ` Paul Evans
2003-04-26  8:01 ` Stef Coene

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.