* [LARTC] CBQ problem
@ 2003-03-13 4:49 Liu Zhiyong
2003-03-13 10:19 ` Liu Zhiyong
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Liu Zhiyong @ 2003-03-13 4:49 UTC (permalink / raw)
To: lartc
this is my CBQ configuration:
DEV=eth1
tc qdisc del dev $DEV root
tc qdisc add dev $DEV root handle 1: cbq avpkt 100 bandwidth 10Mbit cell 8
tc class add dev $DEV parent 1: classid 1:1 cbq rate 10kbit allot 1500 prio
1 cell 8 bounded isolated
tc class add dev $DEV parent 1:1 classid 1:10 cbq rate 1Mbit allot 1500 prio
2 avpkt 15 bounded isolated
tc class add dev $DEV parent 1:1 classid 1:20 cbq rate 7Mbit allot 1500 prio
2 avpkt 60 bounded isolated
tc class add dev $DEV parent 1:1 classid 1:30 cbq rate 200kbit allot 1500
prio 2 avpkt 60 bounded isolated
tc qdisc add dev $DEV parent 1:10 handle 10: sfq perturb 10
tc qdisc add dev $DEV parent 1:20 handle 20: sfq perturb 10
tc qdisc add dev $DEV parent 1:30 handle 30: sfq perturb 10
tc filter add dev $DEV parent 1: protocol ip prio 1 u32 match u8 0x00 0x00
at 0 flowid 1:30
tc filter add dev $DEV parent 1: protocol qroute_uni prio 2 u32 match u8
0x40 0xff at 14 flowid 1:20
tc filter add dev $DEV parent 1: protocol qroute_multi prio 3 u32 match u8
0x40 0xff at 14 flowid 1:20
tc filter add dev $DEV parent 1: protocol qroute_uni prio 4 u32 match u8
0x00 0x00 at 14 flowid 1:10
tc filter add dev $DEV parent 1: protocol qroute_multi prio 5 u32 match u8
0x00 0x00 at 14 flowid 1:10
I want to shape class 1:1 to 10kbit, but it is not successfull. As I know
when class 1:1 is shaped to 10Kbits, its children, can not exceed it, even
if the child's rate is more than class 1:1. But After I applied this tc
configuration, I notice that the bandwidth of class 1:30 is around 200Kbit
(not shape to less than 10Kbit). anyone can help me?
-----------------------------------------
This email was sent using SquirrelMail.
"Webmail for nuts!"
http://squirrelmail.org/
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [LARTC] CBQ problem
2003-03-13 4:49 [LARTC] CBQ problem Liu Zhiyong
@ 2003-03-13 10:19 ` Liu Zhiyong
2003-03-13 15:59 ` Stef Coene
2004-07-28 18:57 ` [LARTC] CBQ Problem Ricardo
2 siblings, 0 replies; 4+ messages in thread
From: Liu Zhiyong @ 2003-03-13 10:19 UTC (permalink / raw)
To: lartc
Some one told me that "bounded", and "isolated" don't work sometimes, is it
true?
----- Original Message -----
From: "Liu Zhiyong" <liuzhiyo@comp.nus.edu.sg>
To: <lartc@mailman.ds9a.nl>
Sent: Thursday, March 13, 2003 12:49 PM
Subject: [LARTC] CBQ problem
> this is my CBQ configuration:
>
> DEV=eth1
> tc qdisc del dev $DEV root
> tc qdisc add dev $DEV root handle 1: cbq avpkt 100 bandwidth 10Mbit cell 8
> tc class add dev $DEV parent 1: classid 1:1 cbq rate 10kbit allot 1500
prio
> 1 cell 8 bounded isolated
> tc class add dev $DEV parent 1:1 classid 1:10 cbq rate 1Mbit allot 1500
prio
> 2 avpkt 15 bounded isolated
> tc class add dev $DEV parent 1:1 classid 1:20 cbq rate 7Mbit allot 1500
prio
> 2 avpkt 60 bounded isolated
> tc class add dev $DEV parent 1:1 classid 1:30 cbq rate 200kbit allot 1500
> prio 2 avpkt 60 bounded isolated
> tc qdisc add dev $DEV parent 1:10 handle 10: sfq perturb 10
> tc qdisc add dev $DEV parent 1:20 handle 20: sfq perturb 10
> tc qdisc add dev $DEV parent 1:30 handle 30: sfq perturb 10
> tc filter add dev $DEV parent 1: protocol ip prio 1 u32 match u8 0x00 0x00
> at 0 flowid 1:30
> tc filter add dev $DEV parent 1: protocol qroute_uni prio 2 u32 match u8
> 0x40 0xff at 14 flowid 1:20
> tc filter add dev $DEV parent 1: protocol qroute_multi prio 3 u32 match u8
> 0x40 0xff at 14 flowid 1:20
> tc filter add dev $DEV parent 1: protocol qroute_uni prio 4 u32 match u8
> 0x00 0x00 at 14 flowid 1:10
> tc filter add dev $DEV parent 1: protocol qroute_multi prio 5 u32 match u8
> 0x00 0x00 at 14 flowid 1:10
>
> I want to shape class 1:1 to 10kbit, but it is not successfull. As I know
> when class 1:1 is shaped to 10Kbits, its children, can not exceed it, even
> if the child's rate is more than class 1:1. But After I applied this tc
> configuration, I notice that the bandwidth of class 1:30 is around 200Kbit
> (not shape to less than 10Kbit). anyone can help me?
>
>
>
> -----------------------------------------
> This email was sent using SquirrelMail.
> "Webmail for nuts!"
> http://squirrelmail.org/
>
>
>
> _______________________________________________
> LARTC mailing list / LARTC@mailman.ds9a.nl
> http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
>
_______________________________________________
LARTC mailing list / LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [LARTC] CBQ problem
2003-03-13 4:49 [LARTC] CBQ problem Liu Zhiyong
2003-03-13 10:19 ` Liu Zhiyong
@ 2003-03-13 15:59 ` Stef Coene
2004-07-28 18:57 ` [LARTC] CBQ Problem Ricardo
2 siblings, 0 replies; 4+ messages in thread
From: Stef Coene @ 2003-03-13 15:59 UTC (permalink / raw)
To: lartc
On Thursday 13 March 2003 11:19, Liu Zhiyong wrote:
> Some one told me that "bounded", and "isolated" don't work sometimes, is it
> true?
Yes. You better remove all the isolated parameters.
I did some tests. You can find the results on www.docum.org on the test page.
I don't have a direct link available to the page with the results.
Stef
>
> ----- Original Message -----
> From: "Liu Zhiyong" <liuzhiyo@comp.nus.edu.sg>
> To: <lartc@mailman.ds9a.nl>
> Sent: Thursday, March 13, 2003 12:49 PM
> Subject: [LARTC] CBQ problem
>
> > this is my CBQ configuration:
> >
> > DEV=eth1
> > tc qdisc del dev $DEV root
> > tc qdisc add dev $DEV root handle 1: cbq avpkt 100 bandwidth 10Mbit cell
> > 8 tc class add dev $DEV parent 1: classid 1:1 cbq rate 10kbit allot 1500
>
> prio
>
> > 1 cell 8 bounded isolated
> > tc class add dev $DEV parent 1:1 classid 1:10 cbq rate 1Mbit allot 1500
>
> prio
>
> > 2 avpkt 15 bounded isolated
> > tc class add dev $DEV parent 1:1 classid 1:20 cbq rate 7Mbit allot 1500
>
> prio
>
> > 2 avpkt 60 bounded isolated
> > tc class add dev $DEV parent 1:1 classid 1:30 cbq rate 200kbit allot 1500
> > prio 2 avpkt 60 bounded isolated
> > tc qdisc add dev $DEV parent 1:10 handle 10: sfq perturb 10
> > tc qdisc add dev $DEV parent 1:20 handle 20: sfq perturb 10
> > tc qdisc add dev $DEV parent 1:30 handle 30: sfq perturb 10
> > tc filter add dev $DEV parent 1: protocol ip prio 1 u32 match u8 0x00
> > 0x00 at 0 flowid 1:30
> > tc filter add dev $DEV parent 1: protocol qroute_uni prio 2 u32 match u8
> > 0x40 0xff at 14 flowid 1:20
> > tc filter add dev $DEV parent 1: protocol qroute_multi prio 3 u32 match
> > u8 0x40 0xff at 14 flowid 1:20
> > tc filter add dev $DEV parent 1: protocol qroute_uni prio 4 u32 match u8
> > 0x00 0x00 at 14 flowid 1:10
> > tc filter add dev $DEV parent 1: protocol qroute_multi prio 5 u32 match
> > u8 0x00 0x00 at 14 flowid 1:10
> >
> > I want to shape class 1:1 to 10kbit, but it is not successfull. As I know
> > when class 1:1 is shaped to 10Kbits, its children, can not exceed it,
> > even if the child's rate is more than class 1:1. But After I applied this
> > tc configuration, I notice that the bandwidth of class 1:30 is around
> > 200Kbit (not shape to less than 10Kbit). anyone can help me?
> >
> >
> >
> > -----------------------------------------
> > This email was sent using SquirrelMail.
> > "Webmail for nuts!"
> > http://squirrelmail.org/
> >
> >
> >
> > _______________________________________________
> > LARTC mailing list / LARTC@mailman.ds9a.nl
> > http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
>
> _______________________________________________
> LARTC mailing list / LARTC@mailman.ds9a.nl
> http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/
--
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] 4+ messages in thread
* [LARTC] CBQ Problem
2003-03-13 4:49 [LARTC] CBQ problem Liu Zhiyong
2003-03-13 10:19 ` Liu Zhiyong
2003-03-13 15:59 ` Stef Coene
@ 2004-07-28 18:57 ` Ricardo
2 siblings, 0 replies; 4+ messages in thread
From: Ricardo @ 2004-07-28 18:57 UTC (permalink / raw)
To: lartc
[-- Attachment #1: Type: text/plain, Size: 2066 bytes --]
Hi.
I want to shape traffic from some IPs in my lan, but I'm w/ trouble. I have a linux box connected to the Internet. In the other side of this box is my LAN. I want to create the following scenario:
My root qdisc is attached to a 100Mbit/s NIC
I want to create a class attached to this qdisc that will limit the traffic at 384Kbit/s.
I want to create two leaf classes that limits the traffic at 256Kbit/s.
I want to attach two sfq qdiscs so two classes are treated equally.
I want to put one LAN IP for each leaf class.
When one IP is downloading a file from internet it will never be more than 256Kbit.
When both IPs is downloading files at the same time, they will never be more than 384Kbit.
(I think that is something like the webserver + smtp example that is in the howto)
My config:
tc qdisc add dev eth1 root handle 1:0 cbq bandwidth 100Mbit avpkt 1000 cell 8
tc class add dev eth1 parent 1:0 classid 1:1 cbq bandwidth 100Mbit rate 384Kbit weight 38Kbit prio 8 allot 1514 cell 8 maxburst 20 avpkt 1000 bounded
tc class add dev eth1 parent 1:1 classid 1:10 cbq bandwidth 100Mbit rate 256Kbit weight 25Kbit prio 8 allot 1514 cell 8 maxburst 20 avpkt 1000
tc class add dev eth1 parent 1:1 classid 1:20 cbq bandwidth 100Mbit rate 256Kbit weight 25Kbit prio 8 allot 1514 cell 8 maxburst 20 avpkt 1000
tc qdisc add dev eth1 parent 1:10 handle 100: sfq
tc qdisc add dev eth1 parent 1:20 handle 200: sfq
tc filter add dev eth1 parent 1:0 protocol ip prio 1 u32 match ip dst 10.0.0.2/32 flowid 1:10
tc filter add dev eth1 parent 1:0 protocol ip prio 1 u32 match ip dst 10.0.0.3/32 flowid 1:20
When I start a download from one machine, the speed is limited at 256Kbit/s (this is OK)
When I start a download from both machines, the speed for each machine is limited to 256Kbit/s. They are getting 512Kbit/s together.
I want limit this speed at 384Kbit/s, so traffic from each machine will never be more than 192Kbps when both are in use.
Why it is not working for me ??? What is the mistake ?
Thank You.
Ricardo
[-- Attachment #2: Type: text/html, Size: 2875 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2004-07-28 18:57 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-03-13 4:49 [LARTC] CBQ problem Liu Zhiyong
2003-03-13 10:19 ` Liu Zhiyong
2003-03-13 15:59 ` Stef Coene
2004-07-28 18:57 ` [LARTC] CBQ Problem Ricardo
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.