All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andy Furniss <andy.furniss@dsl.pipex.com>
To: lartc@vger.kernel.org
Subject: Re: [LARTC] Help with PRIO qdisc and filters
Date: Wed, 11 May 2005 21:40:00 +0000	[thread overview]
Message-ID: <42827BB0.7060107@dsl.pipex.com> (raw)
In-Reply-To: <00a801c554fa$01c48260$0201a8c0@PCIRVCPAVANK>

Pavan Kumar wrote:
> Hi,
> Sorry to bother you all. I have a typical problem sharing DSL upstream
> bandwidth with users. I have 3 types of traffic high-priority,
> medium-priority and low priority. My upstream rate is 960kbits. Traffic (any
> priority) can vary in bandwidth from 0 to 960kbits. I have a test setup
> where I can pump 600kbit of high priority sustained and I have 400kbit of
> low priority traffic sustained. I expect after the 600kbit high-priority
> traffic, the remaining 360kbit should be allocated to the medium and low
> priority. Since I do not have medium-priority everything should go to
> low-priority traffic. However, I do not see that behavior with the following
> tc script I have
>  
> ----------- Begin Script -------------
> # delete any existing qdiscs
> tc qdisc del dev ppp0 root
> # setup PRIO qdisc with 3 bands
> tc qdisc add dev ppp0 root handle 1: prio band 3 priomap 0 0 0 0 0 0 0 0 0 0
> 0 0 0 0 0 0
> # filter traffic for high priority based on TOS field
> tc filter add dev ppp0 parent 1:0 prio 1 protocol ip u32 match ip tos 0x28
> 0xff flowid 1:1
> tc filter add dev ppp0 parent 1:0 prio 1 protocol ip u32 match ip tos 0x48
> 0xff flowid 1:2
> tc filter add dev ppp0 parent 1:0 prio 1 protocol ip u32 match ip tos 0x58
> 0xff  flowid 1:3
>  
> # use ebtables to set the TOS field. First flush the rules
> ebtables -t broute -F
> ebtables -t broute -I BROUTING 1 -j ftos --set-ftos 0x28 -p IPv4 --ip-src
> 192.168.1.151/32
> ebtables -t broute -I BROUTING 2 -j ftos --set-ftos 0x48 -p IPv4 --ip-src
> 192.168.1.152/32
> ebtables -t broute -I BROUTING 3 -j ftos --set-ftos 0x58 -p IPv4 --ip-src
> 192.168.1.153/32
>  
> ----------- End Script ------------------
>  
> What I see is the high priority traffic is leaving at 600kbits as I measure
> it on my test equipment. However, I do not see any low-priority or
> medium-priority traffic coming out of the box. I would appreciate if you
> folks can please give me a hint as to what is happening and also any
> possible solutions. I need hard PRIO but the unused bandwidth should be
> shared by the other traffic. I am using Linux kernel 2.6.8.1 and iproute2
> (iproute2-2.6.8-ss040730.tar.gz).

You need to have prio as an htb class as it doesn't rate limit otherwise .

You'll also need to back off from your dsl rate to allow for overheads 
as they can be significant especially with lots of small packets.

Andy.

_______________________________________________
LARTC mailing list
LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc

      reply	other threads:[~2005-05-11 21:40 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-05-10  0:48 [LARTC] Help with PRIO qdisc and filters Pavan Kumar
2005-05-11 21:40 ` Andy Furniss [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=42827BB0.7060107@dsl.pipex.com \
    --to=andy.furniss@dsl.pipex.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.