All of lore.kernel.org
 help / color / mirror / Atom feed
From: gypsy <gypsy@iswest.com>
To: lartc@vger.kernel.org
Subject: Re: [LARTC] Transfer rate above the desired (tc+htb)
Date: Sun, 24 Jul 2005 18:06:49 +0000	[thread overview]
Message-ID: <42E3D8B9.F93C29FE@iswest.com> (raw)
In-Reply-To: <3941d81c0507201042563b5e45@mail.gmail.com>

Alvaro Motta wrote:
> 
> Hi Andy, thanks for your reply.
> 
> I don't see why the src should be the culprit, since the AB segment is
> 10.4 network and the BC is 192.168. And IMHO 0.0.0.0/0
> 
> Also, after modifying the src, the traffic rate was the same as if no
> qdisc were attached to the interface. I even played with the
> interfaces and the only way to throttle the traffic, is assigning the
> qdisc to the eth0 and having the src and dst as in the script I've
> sent.
> 
> AL

Al,

Somebody may have already helped you solve this; I have not read all
messages from LARTC yet.  If not:
Create 3 filters, each with the same (non zero) prio.  The first to
match 10.4.0.0/16, the second to match 192.168.0.0/24 and the last to
match 0.0.0.0/0 - then see where the packets go by running 
tc -s class ls dev eth0

32kbit = 32,000 bits per second.  32,000 / 8 bits per byte = 4,000 bytes
per second = 4Kbytes per second, and the reported flow rate should be
close to that for the packets that match the filter.
--
gypsy

> On 7/20/05, Andy Furniss <andy.furniss@dsl.pipex.com> wrote:
> > Alvaro Motta wrote:
> > > Hi folks.
> > >
> > > I started to play with tc+htb last week, and I must confess that this
> > > thing is really driving me nuts.
> > >
> > > All we want to do is control bw, with no borrowing.
> > >
> > > In order to get the feeling on this subject, I have setup the
> > > following test bed.
> > >
> > > ---A---B---C---
> > >
> > > On B: eth0 connecting A and eth1 connecting C.
> > >
> > > The script.
> > >
> > > tc qdisc del dev eth0 root
> > > tc qdisc add dev eth0 root handle 1: htb default 50
> > > tc class add dev eth0 parent 1: classid 1:1 htb rate 32kbit ceil 32kbit
> > > tc filter add dev eth0 protocol ip parent 1:0 prio 100 u32 match ip
> > > src 10.4.0.0/16 match ip dst 0.0.0.0/0 classid 1:1
> >
> > Should be src 192.168.0.0/24.
> >
> > Andy.
> >
> >
> > >
> > > If I try to transfer a 1M file from C to A:
> > >
> > > [root@localpost tmp]# wget 192.168.0.23/1M
> > > --09:22:32--  http://192.168.0.23/1M => `1M.8'
> > > Connecting to 192.168.0.23:80... connected.
> > > HTTP request sent, awaiting response... 200 OK
> > > Length: 1,024,000 [text/plain]
> > > 100%[===========>] 1,024,000    183.12K/s    ETA 00:00
> > > 09:22:38 (182.88 KB/s) - `1M' saved [1,024,000/1,024,000]
> > >
> > > Wasn't it supposed to be around the 32KB/s?
> > >
> > > If I play with the numbers (rateÎil) I get the following results:
> > > 128k => 404.78 KB/s
> > > 64k => 337.9 KB/s
> > > 16k => 68.86 KB/s
> > > 8k => 31.12 KB/s
> > > 1k => 3.77 KB/s
> > >
> > > I even tried to set the rate to 1kbps in root, but also led to pretty
> > > much the same results.
> > >
> > > With no qdisc, the rate will go close to 1000 KB/s
> > >
> > > B machine:
> > > 2.6.11-1.1369_FC4
> > > iproute-2.6.11-1
> > > TC HTB version 3.3
> > >
> > > I have no clue on what I am doing wrong. Could anyone browse the above
> > > script and give me hint?
> > >
> > > Thanks in advance,
> > >
> > > AL
> > > _______________________________________________
> > > LARTC mailing list
> > > LARTC@mailman.ds9a.nl
> > > http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc
> > >
> >
> >
> _______________________________________________
> LARTC mailing list
> LARTC@mailman.ds9a.nl
> http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc
_______________________________________________
LARTC mailing list
LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc

      parent reply	other threads:[~2005-07-24 18:06 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-07-20 17:42 [LARTC] Transfer rate above the desired (tc+htb) Alvaro Motta
2005-07-20 18:56 ` Andy Furniss
2005-07-20 20:11 ` Alvaro Motta
2005-07-20 21:11 ` Andy Furniss
2005-07-20 23:14 ` Francisco Pereira
2005-07-24 18:06 ` gypsy [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=42E3D8B9.F93C29FE@iswest.com \
    --to=gypsy@iswest.com \
    --cc=lartc@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.