Hi!

below is my setup ...

                      -------------
                     |             |
              ------>|             |------>
      All       eth0 |   Bridge    | eth1     Router (clients)
    servers   <------|             |<------
                     |             |
                      -------------

And I have sucessfully implemented bandwidth control based on protocol.
Try using the u32 filter.
Eg.
tc filter add dev eth1 parent 10:2 protocol ip prio 3 u32 match ip sport
0x50     0xffff flowid 10:10
tc filter add dev eth1 parent 10:2 protocol ip prio 3 u32 match ip sport
0x1BB    0xffff flowid 10:10
The above are for (HTTP/HTTPS).

I believe ip addresses shaping will be similar.
(Do note that routing based on firewall marking will not work.)

cheers!
/shaoming

----- Original Message -----
From: "Matthias Welwarsky" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, August 22, 2001 3:39 AM
Subject: [Bridge] Bridge and traffic shaping


> Hi all,
>
> I'm trying to set up a transparent traffic shaper using tc and a linux
> bridge. I'm having certain problems with this, namely because I cannot
make
> up tc filters based on ip addresses or protocols.
>
> I'll try to illustrate the (proposed) setup:
>
>
>                    |Internet
>                    |
>                    |
>           +--------+---------+
>           |     Router       |
>           +--------+---------+
>                    |
>                    |
>                    |
>                    | eth0
>           +--------+---------+
>           | Linux Bridge     |
>           +---+---------+----+
>               | eth1    | eth2
>               |         |
>               |         |
>
> Basically, the purpose is to shape the traffic based on whether the
> destination/source of the packet is either eth1 or eth2. traffic from/to
eth1
> shall be limited to 64 kBit/s, traffic from/to eth2 to 1 Mbit/s.
>
> As the bridge is supposed to be transparent, no routing shall take place.
> That also implies that filters cannot be added based on ip addresses or
> networks.
>
> Is it possible to shape the traffic just based on the outgoing interface?
>
> Please Cc: me in a reply, as I'm not currently subscribed to the list.
>
> best regards,
> Matthias
> _______________________________________________
> Bridge mailing list
> [EMAIL PROTECTED]
> http://www.math.leidenuniv.nl/mailman/listinfo/bridge
>

_______________________________________________
Bridge mailing list
[EMAIL PROTECTED]
http://www.math.leidenuniv.nl/mailman/listinfo/bridge

Reply via email to