From mboxrd@z Thu Jan 1 00:00:00 1970 From: Patrick McHardy Date: Wed, 05 Nov 2003 22:25:38 +0000 Subject: Re: [LARTC] Does -j TOS actually do anything? Message-Id: List-Id: References: In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: lartc@vger.kernel.org Where did you get the information that setting TOS with netfilter would affect prio classification ? From what I can see in the source, prio classifies by skb->priority which only inheirits a value from tos field during the forwarding process. I can recall skb->priority also beeing affected by setsockopt(IP_TOS) (besides SO_PRIORITY) but not by simply setting the tos field in the ip header. Best regards, Patrick BTW: the netfilter CLASSIFY target from 2.6 or netfiler patch-o-matic can set skb->priority which is what you need. Thomas Worthington wrote: > Very simple setup: I have several machines, one of which > (192.168.0.198) is used exclusively as a vnc client to a remote site. > I want it to get priority over guff like email and web etc. > > tc qdisc add dev eth1 root handle 1: prio > tc qdisc add dev eth1 parent 1:1 handle 10: pfifo > tc qdisc add dev eth1 parent 1:2 handle 20: pfifo > tc qdisc add dev eth1 parent 1:3 handle 30: pfifo > > iptables -t mangle -I OUTPUT -p icmp -s 192.168.0.198 -j TOS --set-tos 16 > > Effect: zero. All the vnc traffic from x.198 goes into 1:2. > > I've tried all the tables (PREROUTE etc) to no avail. I even tried > applying the TOS change to ALL traffice bound for eth1 (the outside > line) and still saw no change in the queuing despite tcpdump showing > that the tos bits were being set. > > Why does this not work? It seems as if the priority is being set > before iptables' mangle rules are applied. > > Thomas Worthington > _______________________________________________ LARTC mailing list / LARTC@mailman.ds9a.nl http://mailman.ds9a.nl/mailman/listinfo/lartc HOWTO: http://lartc.org/