* [LARTC] tc causes errors on HTML downloads
@ 2002-05-23 21:49 Jason Hunter
2002-05-24 8:26 ` Martin Devera
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Jason Hunter @ 2002-05-23 21:49 UTC (permalink / raw)
To: lartc
LARTC -
I have just started using tc in a closed capacity lab situation. The
lab setup contains 20 machines (win 2000), each with 5 IP address,
downloading a sequence of HTML pages through HTTP. The downloads are
accomplished by a simple browser simulator that is given a list of
pages. It downloads a page and all its sub-components (frames, images,
etc.) and then moves on to the next page in the list. There is a
separate browser simulator running on each IP address (a client).
These simulated clients talk to a web server through a Linux machine
setup up as a router (RedHat 7.3 - 2.4.18-3 stock). I have configured
tc using the attached script to limit the bandwidth between each
simulated IP address and the server.
When I run the test with 40 clients (40 of the 100 simulated IPs)
active, the simulated browser gives errors downloading the images in the
second page (of a two page list). However, when tc is cleared (just
linux routing with no shaping) there are no errors. If I reduce the
number of active clients to 4 or 5 then the errors also disappear.
Can anyone suggest the cause of this behavior and how I might change my
tc configuration to avoid it? Or any other suggestions on how to better
configure the queues to accomplish my goal?
Thanks for you responses,
Jason Hunter
jthunter@ictcompress.com
---- Attached bash script ----------
#!/bin/bash
# add the top level queue to allow us to add other managing queues
tc qdisc add dev eth0 root handle 1:0 cbq bandwidth 100Mbit avpkt 1000
cell 8
# add a shaping queue for traffic to/from the LabNet (7 network)
machines individually
i=10
while (($i <= 200))
do
j=0
while (($j < 5))
do
k=$(($i+$j))
tc class add dev eth0 parent 1:0 classid 1:$k cbq
bandwidth \
100Mbit rate 1200bps weight 1 prio 8 allot 1514 cell 8 maxburst 100
avpkt \ 1000 bounded
tc qdisc add dev eth0 parent 1:$k handle $k: sfq
tc filter add dev eth0 parent 1:0 protocol ip prio 2 u32
match \
ip dst 192.168.7.$k flowid 1:$k
tc filter add dev eth0 parent 1:0 protocol ip prio 2 u32
match \
ip src 192.168.7.$k flowid 1:$k
j=$(($j+1))
done
i=$(($i+10))
done
_______________________________________________
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] tc causes errors on HTML downloads
2002-05-23 21:49 [LARTC] tc causes errors on HTML downloads Jason Hunter
@ 2002-05-24 8:26 ` Martin Devera
2002-05-24 13:07 ` Jason Hunter
2002-05-24 13:10 ` Martin Devera
2 siblings, 0 replies; 4+ messages in thread
From: Martin Devera @ 2002-05-24 8:26 UTC (permalink / raw)
To: lartc
Probably you will have to do closer look (tcpdump
and tcptrace).
From my experiance I'd not believe CBQ much but without
closer expertise it is hard to say what's goin' on.
Also you tried to add IP adresses as both SRC and DST
which is nonsense to do on single interface. It seems
like if you don't understand that shaping shapes egress
traffic only.
devik
On Thu, 23 May 2002, Jason Hunter wrote:
>
> LARTC -
>
> I have just started using tc in a closed capacity lab situation. The
> lab setup contains 20 machines (win 2000), each with 5 IP address,
> downloading a sequence of HTML pages through HTTP. The downloads are
> accomplished by a simple browser simulator that is given a list of
> pages. It downloads a page and all its sub-components (frames, images,
> etc.) and then moves on to the next page in the list. There is a
> separate browser simulator running on each IP address (a client).
>
> These simulated clients talk to a web server through a Linux machine
> setup up as a router (RedHat 7.3 - 2.4.18-3 stock). I have configured
> tc using the attached script to limit the bandwidth between each
> simulated IP address and the server.
>
> When I run the test with 40 clients (40 of the 100 simulated IPs)
> active, the simulated browser gives errors downloading the images in the
> second page (of a two page list). However, when tc is cleared (just
> linux routing with no shaping) there are no errors. If I reduce the
> number of active clients to 4 or 5 then the errors also disappear.
>
> Can anyone suggest the cause of this behavior and how I might change my
> tc configuration to avoid it? Or any other suggestions on how to better
> configure the queues to accomplish my goal?
>
> Thanks for you responses,
>
> Jason Hunter
> jthunter@ictcompress.com
>
>
> ---- Attached bash script ----------
>
> #!/bin/bash
>
> # add the top level queue to allow us to add other managing queues
> tc qdisc add dev eth0 root handle 1:0 cbq bandwidth 100Mbit avpkt 1000
> cell 8
>
> # add a shaping queue for traffic to/from the LabNet (7 network)
> machines individually
> i\x10
> while (($i <= 200))
> do
> j=0
> while (($j < 5))
> do
> k=$(($i+$j))
> tc class add dev eth0 parent 1:0 classid 1:$k cbq
> bandwidth \
> 100Mbit rate 1200bps weight 1 prio 8 allot 1514 cell 8 maxburst 100
> avpkt \ 1000 bounded
> tc qdisc add dev eth0 parent 1:$k handle $k: sfq
> tc filter add dev eth0 parent 1:0 protocol ip prio 2 u32
> match \
> ip dst 192.168.7.$k flowid 1:$k
> tc filter add dev eth0 parent 1:0 protocol ip prio 2 u32
> match \
> ip src 192.168.7.$k flowid 1:$k
>
> j=$(($j+1))
> done
>
> i=$(($i+10))
> done
>
>
> _______________________________________________
> 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] tc causes errors on HTML downloads
2002-05-23 21:49 [LARTC] tc causes errors on HTML downloads Jason Hunter
2002-05-24 8:26 ` Martin Devera
@ 2002-05-24 13:07 ` Jason Hunter
2002-05-24 13:10 ` Martin Devera
2 siblings, 0 replies; 4+ messages in thread
From: Jason Hunter @ 2002-05-24 13:07 UTC (permalink / raw)
To: lartc
Devik -
Actually, I didn't realize that the shaping only shapes on egress. That is interesting. I assume this can be somewhat overcome by applying queues to both interfaces, however, this doesn't provide exactly the same simulation. That is to say, if I am trying to simulate a bounded connection of 1200bps shared between the upload and the download (e.g. a modem) then there isn't a direct way to do this, unless you can filter traffic in both directions into the same queue?
> tc class add dev eth0 parent 1:0 classid 1:$k cbq bandwidth \
> 100Mbit rate 1200bps weight 1 prio 8 allot 1514 cell 8 maxburst 100 avpkt \
> 1000 bounded
As for the errors, I think that I have tracked them down to the maxburst value of 100 in my second level cbq queues. I adjusted this value to between 3 and 5, and got much better results.
- Jason
-----Original Message-----
From: Martin Devera [mailto:devik@cdi.cz]
Sent: Friday, May 24, 2002 4:27 AM
To: Jason Hunter
Cc: lartc@mailman.ds9a.nl
Subject: Re: [LARTC] tc causes errors on HTML downloads
Probably you will have to do closer look (tcpdump
and tcptrace).
From my experiance I'd not believe CBQ much but without
closer expertise it is hard to say what's goin' on.
Also you tried to add IP adresses as both SRC and DST
which is nonsense to do on single interface. It seems
like if you don't understand that shaping shapes egress
traffic only.
devik
_______________________________________________
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] tc causes errors on HTML downloads
2002-05-23 21:49 [LARTC] tc causes errors on HTML downloads Jason Hunter
2002-05-24 8:26 ` Martin Devera
2002-05-24 13:07 ` Jason Hunter
@ 2002-05-24 13:10 ` Martin Devera
2 siblings, 0 replies; 4+ messages in thread
From: Martin Devera @ 2002-05-24 13:10 UTC (permalink / raw)
To: lartc
Use IMQ. I will allow you it.
On Fri, 24 May 2002, Jason Hunter wrote:
> Devik -
>
> Actually, I didn't realize that the shaping only shapes on egress. That is interesting. I assume this can be somewhat overcome by applying queues to both interfaces, however, this doesn't provide exactly the same simulation. That is to say, if I am trying to simulate a bounded connection of 1200bps shared between the upload and the download (e.g. a modem) then there isn't a direct way to do this, unless you can filter traffic in both directions into the same queue?
>
>
> > tc class add dev eth0 parent 1:0 classid 1:$k cbq bandwidth \
> > 100Mbit rate 1200bps weight 1 prio 8 allot 1514 cell 8 maxburst 100 avpkt \
> > 1000 bounded
>
> As for the errors, I think that I have tracked them down to the maxburst value of 100 in my second level cbq queues. I adjusted this value to between 3 and 5, and got much better results.
>
> - Jason
>
> -----Original Message-----
> From: Martin Devera [mailto:devik@cdi.cz]
> Sent: Friday, May 24, 2002 4:27 AM
> To: Jason Hunter
> Cc: lartc@mailman.ds9a.nl
> Subject: Re: [LARTC] tc causes errors on HTML downloads
>
> Probably you will have to do closer look (tcpdump
> and tcptrace).
> >From my experiance I'd not believe CBQ much but without
> closer expertise it is hard to say what's goin' on.
> Also you tried to add IP adresses as both SRC and DST
> which is nonsense to do on single interface. It seems
> like if you don't understand that shaping shapes egress
> traffic only.
> devik
>
>
>
>
>
_______________________________________________
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
end of thread, other threads:[~2002-05-24 13:10 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-05-23 21:49 [LARTC] tc causes errors on HTML downloads Jason Hunter
2002-05-24 8:26 ` Martin Devera
2002-05-24 13:07 ` Jason Hunter
2002-05-24 13:10 ` Martin Devera
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox