[LARTC] Remarking non conformant packets as AF13 from AF11

Linux Advanced Routing and Traffic Control

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

I am trying to implement a simple scaled-down version of the AF traffic
class type. As such I basically want to remark non-conforming AF11
packets to AF13. Here is m script that I have been using on the ingress
router of my network:


----------------------------------------
Link=3D'dev eth1'

Rate1=3D'rate 800Kbit'
Rate2=3D'rate 2500Kbit'

Burst=3D'burst 9K'

Action=3D'continue'

Match1=3D'match ip src 192.6.0.90 match ip dst 10.37.1.63 match ip sport
6970 0xffff match ip protocol 17 0xff'
Match2=3D'match ip src 192.6.0.90 match ip dst 10.37.1.63 match ip dport
5005 0xffff match ip protocol 17 0xff'
Match3=3D'match ip src 0/0'

Meter1=3D"police $Rate1 $Burst $Action"
Meter2=3D"police $Rate2 $Burst $Action"

./tc qdisc add $Link handle 1:0 root dsmark indices 64
./tc class change $Link classid 1:1 dsmark mask 0x3 value 0x28
./tc class change $Link classid 1:2 dsmark mask 0x3 value 0x38
./tc class change $Link classid 1:3 dsmark mask 0x3 value 0x0

./tc filter add $Link parent 1:0 protocol ip prio 1 handle 1: u32 divisor
1
./tc filter add $Link parent 1:0 prio 1 u32 $Match1 $Meter1 flowid 1:1
./tc filter add $Link parent 1:0 prio 1 u32 $Match2 $Meter2 flowid 1:1
./tc filter add $Link parent 1:0 prio 1 u32 $Match3 flowid 1:3

----------------------------------------

There is traffic travelling across the network through two ports (6970 -
Video streaming, and 5005 - Iperf traffic gernerator). When I monitor the
packets using Ethereal, it can be seen that most packets are remarked
0x28 (AF11). However, non-conforming traffic is just remarked as 0x00 (BE
class) which is not what I would like. I would like all non-conforming
packets to be remarked 0x38 (AF13) which would afford them special
treament further down my network.

I have a suspiscion that it might have something to do with the fact the
I am using "continue" as the action used for each of my meters, but can't
be sure. If someone could clarify this or suggest anything or offer
sample scripts then I'd be most grateful, or if anyone would like more
details then I'd be happy to give it to them.

Thanks very much,
Jesse
--=20
  Jesse
  jkielthy@xxxxxxxxxxx

--=20
http://www.fastmail.fm - Same, same, but different=85


[Index of Archives]     [LARTC Home Page]     [Netfilter]     [Netfilter Development]     [Network Development]     [Bugtraq]     [GCC Help]     [Yosemite News]     [Linux Kernel]     [Fedora Users]
  Powered by Linux