All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mohan Sundaram <mohan.tux@gmail.com>
To: lartc@vger.kernel.org
Subject: Re: [LARTC] linux-2.4.22 + bridge + traffic control by MAC.
Date: Wed, 08 Nov 2006 11:49:52 +0000	[thread overview]
Message-ID: <4551C190.1000603@vsnl.com> (raw)
In-Reply-To: <6ec85fe20611062225t1bee861fq93ed5cb9f66c3ff6@mail.gmail.com>

Henry Bin wrote:
> On 11/7/06, Покотиленко Костик <casper@meteor.dp.ua> wrote:
>> В Вто, 07/11/2006 в 14:25 +0800, Henry Bin пишет:
>> > Dear all,
>> >
>> > I am working on a linux box (2.4.22 kernel) which is used as a
>> > bridge. And I want to add traffic control rules on it by client's 
>> MAC. Does anyone has such experience on how to do that? Thank you very 
>> much!!
>>
>> bridge-utils
>> iptables
>> ebtables
>>
> Oh, could you please give me a example about how to do that?
> What's I want is to limit the bandwidth for specified MAC. For
> example, I just want to give 3Mbps bandwidth to the PC which has MAC
> address--00:40:33:44:23:44.
> 
> Thanks a lot!
>> -- 
>> Покотиленко Костик <casper@meteor.dp.ua>
>>
You can mark (fwmark) a packet based on the source MAC in 
iptables/ebtables. In the case of bridge, the packet needs to be marked 
by ebtables. tc allows classification by fwmark.

Create a class and assign 3Mbps rate to it. Create a tc filter to send 
all traffic with fwmark 1 to this class. Create a ebtables rule that 
marks all packets coming from MAC address--00:40:33:44:23:44 with fwmark 1.

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

  parent reply	other threads:[~2006-11-08 11:49 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-11-07  6:25 [LARTC] linux-2.4.22 + bridge + traffic control by MAC Henry Bin
2006-11-07  9:50 ` 
2006-11-08  9:25 ` Henry Bin
2006-11-08 11:49 ` Mohan Sundaram [this message]
2006-11-08 21:57 ` Leigh Sharpe
2006-11-10  2:45 ` Henry Bin

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=4551C190.1000603@vsnl.com \
    --to=mohan.tux@gmail.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.