From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-la0-x22d.google.com (mail-la0-x22d.google.com [IPv6:2a00:1450:4010:c03::22d]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by huchra.bufferbloat.net (Postfix) with ESMTPS id 9000121F53F for ; Fri, 21 Nov 2014 04:04:58 -0800 (PST) Received: by mail-la0-f45.google.com with SMTP id gq15so4123116lab.32 for ; Fri, 21 Nov 2014 04:04:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=50lmcZoEOdX8BNjudenxp+EXRfVAdgm8WrdrL/Wnu6w=; b=TZkiMIzBQl9gVv8hnQPhJwgtkVRxkYe6iy2xIlrDeOWcqAQnNAd4N2cwjrdAXiLCCz JgAlh5plTNkfEFegS6ZvqUO2SaVYdFm2e6Dhs9kKPMVAdeBUlNizLEkEmN+6zQyYTbbv YKo4yy54YbA2qv814YyjTk5JQYpe61F50WmIcMv5cVdpV11Tb5+ISiy+mP3AV7eH/V90 5Eio5lQNn0bPcpqZKch6GrZcOuAMKmekkuiMnDEgh1WlC2lc2R6A2mz+DKIBeA7G0KsS ydSgNXs7Hu4Lq7DA7yKef6KE3JqEOdqvILdjSNyLpWPIxedUh703lyn0JDN8kynpqC8G t6wA== X-Received: by 10.112.25.73 with SMTP id a9mr4198873lbg.10.1416571495529; Fri, 21 Nov 2014 04:04:55 -0800 (PST) MIME-Version: 1.0 Received: by 10.25.36.194 with HTTP; Fri, 21 Nov 2014 04:04:35 -0800 (PST) In-Reply-To: <1467AE3E-F8D9-4937-8358-DEE9988CC879@gmx.de> References: <1467AE3E-F8D9-4937-8358-DEE9988CC879@gmx.de> From: Dane Medic Date: Fri, 21 Nov 2014 13:04:35 +0100 Message-ID: To: Sebastian Moeller Content-Type: multipart/alternative; boundary=001a11c3f5bcca411405085d4028 Cc: "cerowrt-devel@lists.bufferbloat.net" Subject: Re: [Cerowrt-devel] Torrents are too fast X-BeenThere: cerowrt-devel@lists.bufferbloat.net X-Mailman-Version: 2.1.13 Precedence: list List-Id: Development issues regarding the cerowrt test router project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Nov 2014 12:05:27 -0000 --001a11c3f5bcca411405085d4028 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable hm, it looks like somebody is still maintaining the l7-protocols package in openwrt -> https://github.com/openwrt/packages/blob/5600fdeeeec861c0359d6d53d1a1518b18= 17630d/net/l7-protocols/Makefile https://github.com/gwlim/wr1043nd-chaos-calmer-patch/blob/master/openwrt-pa= tch/037-fix-l7-filter.patch 2014-11-21 12:51 GMT+01:00 Sebastian Moeller : > HI Dane hi Dave, > > > On Nov 20, 2014, at 17:25 , Dane Medic wrote: > > > Thank you for advice Dave. I'm just looking around how to set-up layer = 7 > inspection, I've also found this -> > http://luci.subsignal.org/trac/browser/luci/trunk/contrib/package/freifun= k-p2pblock?rev=3D > > It would be very nice if someone could "merge" this with simple.qos, I > don't really know how, yet. > > See the last comment in https://dev.openwrt.org/ticket/8590 it seems that > L7 filters are on the way out in openwrt. If I understand correctly L7 do= es > regular expression search of each packet (which are documented as not > perfect and potentially slow), I would not be amazed if that would be > really costly on your wndr. You might be =E2=80=9Csaved=E2=80=9D though b= y your slow link > ;) . Also L& filters doe not really work with encrypted packets, so a > malicious (actually mischievous would be enough) torrent client could mas= k > its packets out of the filter match by encryption. > > > > > > 2014-11-20 15:40 GMT+01:00 Dave Taht : > > I would be surprised if you could tolerate a *single* big download > > while watching a movie, at 4mbit/512k, much less torrents, which are 6 > > or more. > > > > That said, most torrent clients are configurable in several ways. > > > > 1) You can limit the number of download flows to something far less > > than 6. Try 1 or 2. > > > > 2) You can typically rate limit them in the client to a lower rate > > during the day and a higher rate at night. > > > > 3) You can tell them to mark the torrents as background (QoS marking > > CS1), but that only helps on uploads vs the simple.qos script. > > I think this is the best approach to take, actively configure the > torrent client to be a good citizen... > > > > > At the router itself, you can try things like identifying torrent > > traffic via a consistent port number (if you have one) to toss it into > > the background queue , or try qos-scripts which has a layer 7 dpi > > tool. > > If you have just a single torrent application you are concerned > with you could capture a few incoming and outgoing packets and see whethe= r > you can find a =E2=80=9Csignature=E2=80=9D for these packets in the data = and then create > =E2=80=9Ctc filter=E2=80=9D invocations just against your specific torren= t application=E2=80=A6 > I fear there is no automatic solution that will get all this > right, and hence the prudent way would be for SQM to use the background > queue as the default queue for everything (instead of the best effort > queue) and then selectively promote reasonable traffic to the other queue= s. > (But that means everything not classified will share a queue /suffer with > the torrents until special cased by a promotion rule). > > > Best Regards > Sebastian > > > > > > > > > > > On Thu, Nov 20, 2014 at 6:13 AM, Dane Medic wrote: > > > dpreed, thank you for response. I'm already using fq_codel with > cerowrt and > > > I don't think it does what I want (or maybe I want too much :) > > > > > > So the steps I've made: > > > flashed wndr3700v2 with cerowrt 3.10.50-1 then I've measured: > > > > > > root@cerowrt:/usr/lib/CeroWrtScripts# sh betterspeedtest.sh -p > wlan-si.net > > > -t 120 > > > 2014-11-20 12:18:34 Testing against netperf.bufferbloat.net (ipv4) > with 5 > > > simultaneous sessions while pinging wlan-si.net (120 seconds in each > > > direction) > > > > .........................................................................= ................................................ > > > Download: 3.78 Mbps > > > Latency: (in msec, 119 pings, 0.00% packet loss) > > > Min: 13.077 > > > 10pct: 251.522 > > > Median: 317.851 > > > Avg: 308.497 > > > 90pct: 371.033 > > > Max: 376.132 > > > > .........................................................................= ................................................... > > > Upload: 0.48 Mbps > > > Latency: (in msec, 103 pings, 0.00% packet loss) > > > Min: 12.278 > > > 10pct: 12.727 > > > Median: 18.359 > > > Avg: 23.256 > > > 90pct: 33.971 > > > Max: 180.303 > > > > > > Then I've put these commands: > > > > > > uci set sqm.ge00.enabled=3D1 > > > uci set sqm.ge00.download=3D3200 > > > uci set sqm.ge00.qdisc=3Dnfq_codel > > > uci commit sqm > > > reboot > > > > > > And another measure: > > > > > > root@cerowrt:/usr/lib/CeroWrtScripts# sh betterspeedtest.sh -p > wlan-si.net > > > -t 120 > > > 2014-11-20 12:49:05 Testing against netperf.bufferbloat.net (ipv4) > with 5 > > > simultaneous sessions while pinging wlan-si.net (120 seconds in each > > > direction) > > > > .........................................................................= ................................................ > > > Download: 2.74 Mbps > > > Latency: (in msec, 121 pings, 0.00% packet loss) > > > Min: 12.210 > > > 10pct: 13.002 > > > Median: 15.077 > > > Avg: 15.095 > > > 90pct: 16.968 > > > Max: 18.599 > > > > .........................................................................= .................................................... > > > Upload: 0.49 Mbps > > > Latency: (in msec, 101 pings, 0.00% packet loss) > > > Min: 12.255 > > > 10pct: 12.684 > > > Median: 16.679 > > > Avg: 23.100 > > > 90pct: 34.019 > > > Max: 170.173 > > > > > > The tests doesn't look bad, but the problem is I watch a video clip o= n > > > youtube and my sister starts torrent client, I can't watch anymore. > > > > > > Cheers > > > > > > _______________________________________________ > > > Cerowrt-devel mailing list > > > Cerowrt-devel@lists.bufferbloat.net > > > https://lists.bufferbloat.net/listinfo/cerowrt-devel > > > > > > > > > > > -- > > Dave T=C3=A4ht > > > > thttp://www.bufferbloat.net/projects/bloat/wiki/Upcoming_Talks > > > > _______________________________________________ > > Cerowrt-devel mailing list > > Cerowrt-devel@lists.bufferbloat.net > > https://lists.bufferbloat.net/listinfo/cerowrt-devel > > --001a11c3f5bcca411405085d4028 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
hm, it looks like somebody is still maintaining the l7-pro= tocols package in openwrt -> https://github.com/gwlim/wr1043nd-chaos-calmer-patch/blob/master/ope= nwrt-patch/037-fix-l7-filter.patch
=
2014-11-21 12:51 GMT+01:00 Sebastian Moeller= <moeller0@gmx.de>:
HI Dane = hi Dave,


On Nov 20, 2014, at 17:25 , Dane Medic <dm70dm@gmail.com> wrote:

> Thank you for advice Dave. I'm just looking around how to set-up l= ayer 7 inspection, I've also found this -> http://luci.subsignal.org/trac/browser/luci/trunk/co= ntrib/package/freifunk-p2pblock?rev=3D
> It would be very nice if someone could "merge" this with sim= ple.qos, I don't really know how, yet.

See the last comment in https://dev.openwrt.org/ticket/8590 it seems that= L7 filters are on the way out in openwrt. If I understand correctly L7 doe= s regular expression search of each packet (which are documented as not per= fect and potentially slow), I would not be amazed if that would be really c= ostly on your wndr. You might be =E2=80=9Csaved=E2=80=9D though by your slo= w link ;) .=C2=A0 Also L& filters doe not really work with encrypted pa= ckets, so a malicious (actually mischievous would be enough) torrent client= could mask its packets out of the filter match by encryption.


>
> 2014-11-20 15:40 GMT+01:00 Dave Taht <dave.taht@gmail.com>:
> I would be surprised if you could tolerate a *single* big download
> while watching a movie, at 4mbit/512k, much less torrents, which are 6=
> or more.
>
> That said, most torrent clients are configurable in several ways.
>
> 1) You can limit the number of download flows to something far less > than 6. Try 1 or 2.
>
> 2) You can typically rate limit them in the client to a lower rate
> during the day and a higher rate at night.
>
> 3) You can tell them to mark the torrents as background (QoS marking > CS1), but that only helps on uploads vs the simple.qos script.

=C2=A0 =C2=A0 =C2=A0 =C2=A0 I think this is the best approach to tak= e, actively configure the torrent client to be a good citizen...

>
> At the router itself, you can try things like identifying torrent
> traffic via a consistent port number (if you have one) to toss it into=
> the background queue , or try qos-scripts which has a layer 7 dpi
> tool.

=C2=A0 =C2=A0 =C2=A0 =C2=A0 If you have just a single torrent applic= ation you are concerned with you could capture a few incoming and outgoing = packets and see whether you can find a =E2=80=9Csignature=E2=80=9D for thes= e packets in the data and then create =E2=80=9Ctc filter=E2=80=9D invocatio= ns just against your specific torrent application=E2=80=A6
=C2=A0 =C2=A0 =C2=A0 =C2=A0 I fear there is no automatic solution that will= get all this right, and hence the prudent way would be for SQM to use the = background queue as the default queue for everything (instead of the best e= ffort queue) and then selectively promote reasonable traffic to the other q= ueues. (But that means everything not classified will share a queue /suffer= with the torrents until special cased by a promotion rule).


Best Regards
=C2=A0 =C2=A0 =C2=A0 =C2=A0 = Sebastian

>
>
>
>
> On Thu, Nov 20, 2014 at 6:13 AM, Dane Medic <dm70dm@gmail.com> wrote:
> > dpreed, thank you for response. I'm already using fq_codel wi= th cerowrt and
> > I don't think it does what I want (or maybe I want too much := )
> >
> > So the steps I've made:
> > flashed wndr3700v2 with cerowrt 3.10.50-1 then I've measured:=
> >
> > root@cerowrt:/usr/lib/CeroWrtScripts# sh betterspeedtest.sh -p wlan-si.net
> > -t 120
> > 2014-11-20 12:18:34 Testing against netperf.bufferbloat.net (ipv4) with 5 > > simultaneous sessions while pinging wlan-si.net (120 seconds in each
> > direction)
> > .................................................................= ........................................................
> >=C2=A0 Download:=C2=A0 3.78 Mbps
> >=C2=A0 =C2=A0Latency: (in msec, 119 pings, 0.00% packet loss)
> >=C2=A0 =C2=A0 =C2=A0 =C2=A0Min: 13.077
> >=C2=A0 =C2=A0 =C2=A010pct: 251.522
> >=C2=A0 =C2=A0 Median: 317.851
> >=C2=A0 =C2=A0 =C2=A0 =C2=A0Avg: 308.497
> >=C2=A0 =C2=A0 =C2=A090pct: 371.033
> >=C2=A0 =C2=A0 =C2=A0 =C2=A0Max: 376.132
> > .................................................................= ...........................................................
> >=C2=A0 =C2=A0 Upload:=C2=A0 0.48 Mbps
> >=C2=A0 =C2=A0Latency: (in msec, 103 pings, 0.00% packet loss)
> >=C2=A0 =C2=A0 =C2=A0 =C2=A0Min: 12.278
> >=C2=A0 =C2=A0 =C2=A010pct: 12.727
> >=C2=A0 =C2=A0 Median: 18.359
> >=C2=A0 =C2=A0 =C2=A0 =C2=A0Avg: 23.256
> >=C2=A0 =C2=A0 =C2=A090pct: 33.971
> >=C2=A0 =C2=A0 =C2=A0 =C2=A0Max: 180.303
> >
> > Then I've put these commands:
> >
> > uci set sqm.ge00.enabled=3D1
> > uci set sqm.ge00.download=3D3200
> > uci set sqm.ge00.qdisc=3Dnfq_codel
> > uci commit sqm
> > reboot
> >
> > And another measure:
> >
> > root@cerowrt:/usr/lib/CeroWrtScripts# sh betterspeedtest.sh -p wlan-si.net
> > -t 120
> > 2014-11-20 12:49:05 Testing against netperf.bufferbloat.net (ipv4) with 5 > > simultaneous sessions while pinging wlan-si.net (120 seconds in each
> > direction)
> > .................................................................= ........................................................
> >=C2=A0 Download:=C2=A0 2.74 Mbps
> >=C2=A0 =C2=A0Latency: (in msec, 121 pings, 0.00% packet loss)
> >=C2=A0 =C2=A0 =C2=A0 =C2=A0Min: 12.210
> >=C2=A0 =C2=A0 =C2=A010pct: 13.002
> >=C2=A0 =C2=A0 Median: 15.077
> >=C2=A0 =C2=A0 =C2=A0 =C2=A0Avg: 15.095
> >=C2=A0 =C2=A0 =C2=A090pct: 16.968
> >=C2=A0 =C2=A0 =C2=A0 =C2=A0Max: 18.599
> > .................................................................= ............................................................
> >=C2=A0 =C2=A0 Upload:=C2=A0 0.49 Mbps
> >=C2=A0 =C2=A0Latency: (in msec, 101 pings, 0.00% packet loss)
> >=C2=A0 =C2=A0 =C2=A0 =C2=A0Min: 12.255
> >=C2=A0 =C2=A0 =C2=A010pct: 12.684
> >=C2=A0 =C2=A0 Median: 16.679
> >=C2=A0 =C2=A0 =C2=A0 =C2=A0Avg: 23.100
> >=C2=A0 =C2=A0 =C2=A090pct: 34.019
> >=C2=A0 =C2=A0 =C2=A0 =C2=A0Max: 170.173
> >
> > The tests doesn't look bad, but the problem is I watch a vide= o clip on
> > youtube and my sister starts torrent client, I can't watch an= ymore.
> >
> > Cheers
> >
> > _______________________________________________
> > Cerowrt-devel mailing list
> > Cerowrt-de= vel@lists.bufferbloat.net
> > https://lists.bufferbloat.net/listinfo/cerowrt-devel<= br> > >
>
>
>
> --
> Dave T=C3=A4ht
>
> thttp://www.bufferbloat.net/projects/bloat/wiki/Upcom= ing_Talks
>
> _______________________________________________
> Cerowrt-devel mailing list
> Cerowrt-devel@l= ists.bufferbloat.net
> https://lists.bufferbloat.net/listinfo/cerowrt-devel


--001a11c3f5bcca411405085d4028--