LARTC
[Top] [All Lists]

[LARTC] Problems matching tos on port 554

To: <lartc@mailman.ds9a.nl>
Subject: [LARTC] Problems matching tos on port 554
From: "Bolivar Diaz Galarza" <bolivardg@ml.com.mx>
Date: Tue, 30 Jan 2007 17:21:52 -0600
Delivered-to: sp-com-lists@consult.net
Delivered-to: lartc-list@securepoint.com
Delivered-to: lartc@outpost.ds9a.nl
List-archive: <http://mailman.ds9a.nl/pipermail/lartc>
List-help: <mailto:lartc-request@mailman.ds9a.nl?subject=help>
List-id: "Mailinglist of the Linux Advanced Routing &amp; Traffic Control project" <lartc.mailman.ds9a.nl>
List-post: <mailto:lartc@mailman.ds9a.nl>
List-subscribe: <http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc>, <mailto:lartc-request@mailman.ds9a.nl?subject=subscribe>
List-unsubscribe: <http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc>, <mailto:lartc-request@mailman.ds9a.nl?subject=unsubscribe>
Sender: lartc-bounces@mailman.ds9a.nl
Thread-index: AcdExWzU9yE+x3inTpiGWe+C05YxVw==
Hi There,
 
I am trying to match mac address and tos at the same time. It mostly works for all ports, but recently I discovered that it doesn't, for example it does not work on port 554.
 
For each client I have two classes, one is the "good" traffic that I mark using iptables with the line, for example:
 
/sbin/iptables -t mangle -A PREROUTING -p tcp --sport 554 -j TOS --set-tos 0x10
 
Later on, I use tc filter to send the packets marked with tos 0x10 to the proper class which will be 1:1192 in this case, and the rest of the traffic matching that clients MAC address continues to 1:2192:
 
BAJADA="/sbin/tc filter add dev eth1 protocol ip parent 1:0 prio 1 u32 match u16 0x0800 0xffff at -2"
$BAJADA match u32 0x5bb517c8 0xffffffff at -12 match u16 0x0011 0xffff at -14 match ip tos 0x10 0xff flowid 1:1192
$BAJADA match u32 0x5bb517c8 0xffffffff at -12 match u16 0x0011 0xffff at -14 flowid 1:2192
 
I thought about marking the packets with iptables -j MARK --set-mark but I can't find a way of making this work and matching the MAC address at the same time.
 
Any help will be greatly appreciated.
 
Bolivar,
_______________________________________________
LARTC mailing list
LARTC@mailman.ds9a.nl
http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc
<Prev in Thread] Current Thread [Next in Thread>
  • [LARTC] Problems matching tos on port 554, Bolivar Diaz Galarza <=