From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andy Furniss Date: Mon, 09 Jan 2006 23:57:53 +0000 Subject: Re: [LARTC] HTB - not borrowing, not exceeding rate Message-Id: <43C2F881.3010108@dsl.pipex.com> List-Id: References: <200601081659.24726.kajtek@biezanow.net> In-Reply-To: <200601081659.24726.kajtek@biezanow.net> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: lartc@vger.kernel.org Kajetan Staszkiewicz wrote: > Here is current setup: > > tc qdisc del root dev eth2.24 2>/dev/null > tc qdisc add root dev eth2.24 handle 1: htb default 1 > > # main rate limitation for whole connection (802.11a radio link) > tc class add dev eth2.24 parent 1: classid 1:1 htb rate 15000kbit ceil > 15000kbit burst 10kbit Burst too small - it's realated to HZ and also should be at least as big as child bursts. http://luxik.cdi.cz/~devik/qos/htb/manual/userg.htm#burst > > # class for internet connections - this one can use nearly whole link > tc class add dev eth2.24 parent 1:1 classid 1:6667 htb rate 12000kbit ceil > 13500kbit burst 100kbit > > # class for in-network p2p connections - this one has lower guaranteed rate > tc class add dev eth2.24 parent 1:1 classid 1:6666 htb rate 3000kbit ceil > 14000kbit burst 10kbit > tc qdisc add dev eth2.24 parent 1:6666 handle 6666: sfq perturb 5 quantum > 1500b I would condider using htb prio here and sfq peturb causes packet reordering so 5 is a bit low. SFQ is really best for bulk traffic. > # now in-network p2p traffic. if it comes from other LANs then direct it to > # 1:6666 > tc filter add dev eth2.24 protocol ip parent 1:0 u32 match ip src > 192.168.5.0/24 flowid 1:6666 > tc filter add dev eth2.24 protocol ip parent 1:0 u32 match ip src > 192.168.4.0/24 flowid 1:6666 I think these should be before the other filters. Andy. _______________________________________________ LARTC mailing list LARTC@mailman.ds9a.nl http://mailman.ds9a.nl/cgi-bin/mailman/listinfo/lartc