From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wg0-x22b.google.com (mail-wg0-x22b.google.com [IPv6:2a00:1450:400c:c00::22b]) (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 32082201260 for ; Thu, 16 Jan 2014 14:08:05 -0800 (PST) Received: by mail-wg0-f43.google.com with SMTP id y10so3720301wgg.34 for ; Thu, 16 Jan 2014 14:08:03 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; bh=5l1YZjVgWvqmIEKcOvWxeXF6c6UH9gaRVAtyHfceVE8=; b=uyDlgAkNxub/FRVUdBwrchWTlXl8DUXk674eaIqeycrqSmULxCRvjRAqwYTSrRYlgh nwFQyhQvv1Z0620p5Wu0j8QmAap3V6yNbcWtWHd61jCmWnuCxtpNJ4iulOAmxdf/mH/n vn0Od5hTTey0PGR0Z0M2k304g+zkKxMHwrxocprCIF2/JDEgHwSZc7zt8E+40Ois/Dv3 emvHjUdBV31KcuaPRrzpXKsQO69HUddnHeoL22lSyAdQ0/LkXw+gwwFglg5yDUBUnaMX UZyyCYpHTAOCaQ3ARrWClMKqEZGrGW0ws+BzQFE3scj+LakAokCWBUJYiF5WE5JPpN2F gkzw== MIME-Version: 1.0 X-Received: by 10.180.76.42 with SMTP id h10mr10286760wiw.46.1389910082927; Thu, 16 Jan 2014 14:08:02 -0800 (PST) Received: by 10.217.123.69 with HTTP; Thu, 16 Jan 2014 14:08:02 -0800 (PST) In-Reply-To: References: Date: Thu, 16 Jan 2014 17:08:02 -0500 Message-ID: From: Dave Taht To: Aaron Wood Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: cerowrt-devel Subject: Re: [Cerowrt-devel] Managed to break 802.11n (on a 3800) 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: Thu, 16 Jan 2014 22:08:26 -0000 Several quick notes: (I am behind on my mail) On Thu, Jan 16, 2014 at 10:03 AM, Aaron Wood wrote: > All, > > I'm noting this here in case anyone is interested. After I write this up= , > I'm going to start from scratch on the configuration, and factory-reset t= he > router. > > =3D=3D=3D=3D=3D > > The 5GHz radio on my 3800 seems to be in a very odd state. I'm not quire > sure what state it's in, but it seems to be only doing HT20 1x1. And in = a > fairly broken manner at that. Well, I've noted that until we get per station queueing in the ath9k driver itself, wifi performance is not going to be very good. > Running the rrul test (over wifi directly to the router as the netserver)= , > tcp uploads were 25Mbps or so, but download was 5Mbps. This is me 1-2 > meters from the router. Load was never more than 0.33. (I can share the > results of people are interested). One set of parameters worth fiddling with are the defaults for aggregation in /usr/sbin/debloat which historically have been set very low for the best balance of latency and performance. Presently those are set to: ["qlen_vo"] =3D 2, ["qlen_vi"] =3D 4, ["qlen_be"] =3D 12, ["qlen_bk"] =3D 12, change it to ["qlen_vi"] =3D 12, ["qlen_be"] =3D 128, ["qlen_bk"] =3D 128, Your bandwidth should go up (unless there's a genuine problem elsewhere), and your latency go to hell. Another (better) idea is to use a better filter (problem in creating such noted in an earlier email) that only sorts on destination ips, with a bigger quantum. I haven't had any success in creating that filter. That + I have long thought that for wifi, a quantum of 1514, or double or treble that, was a better idea than the current defaults, *given the underlying driver infrastructure*, and NOT in the presence of wireless-g. change this to something else ["CODEL_LL_QUANTUM"] =3D 300 then you can run IFACE=3Dsw00 QMODEL=3Dfq_codel_ll /usr/sbin/debloat # for 2.4ghz (you can also fiddle with all of these params on the command line qlen_vi=3D12 qlen_be=3D64 qlen_bk=3D64 IFACE=3Dsw00 QMODEL=3Dfq_codel_ll /u= sr/sbin/debloat A third, if you are running linux on the client, is to run fq_codel on it's wifi interfaces via the debloat script as well. There's tons of latency hidden in everybody's wifi drivers, and part of your problem is coming from that. But the up/down ratio problem you are seeing is pretty real. > > After a full power cycle, wifi isn't coming up at all. The channel you selected is not legal in country "FR". (I didn't know if an= y 5ghz was legal yet at all in FR(?)) > =3D=3D=3D=3D=3D > > How I got here: > > > I'm in France, and had dutifully set my unit with the FR country code whe= n > setting up CeroWRT. I had noticed some odd latencies (periodic 100-200ms > latency every 10-20 seconds over wifi) on the 5GHz network. The router w= as > on channel 36, and I wanted to move it up to the far-upper ranges, so I > tried to specify a "custom" channel to do so (140). This was the channel= I > thought I had been using with stock (Netgear) firmware. Well, it's rejected by the registration database. http://wireless.kernel.org/en/developers/Regulatory arguably the gui should reject attempts to select channels not in the datab= ase. 140 isn't legal in the US either, so far as I recall. you should definitely also have a consistent country code per radio. > Wifi didn't come back up after applying the changes, and the luci interfa= ce > seemed to be tripping up over stuff that it was reading out of the > configuration files. > > I ssh'd in via ethernet, and fixed up the configurations by hand. > > Except the driver is still reporting that the 5GHz network won't kick int= o > 802.11n modes, and won't use HT40. It seems to be sure it's configured f= or > it, but isn't using it. Might be being rejected as before. > > Further, digging into the rc_stats files with the minstrel speeds, I foun= d > some very odd data (not what I was expecting to see: > > (laptop, which can do 2x2 HT40) > rate throughput ewma prob this prob this succ/attempt success > attempts > D 6 6.0 99.9 100.0 2( 2) 65 > 65 > 9 0.0 0.0 0.0 0( 0) 0 > 0 > 12 2.9 25.0 100.0 0( 0) 1 > 1 > 18 4.3 25.0 100.0 0( 0) 1 > 1 > 24 5.6 25.0 100.0 0( 0) 1 > 1 > A P 36 32.4 99.9 100.0 0( 0) 51 > 51 > C 48 10.4 25.0 100.0 0( 0) 1 > 1 > B 54 11.5 25.0 100.0 0( 0) 1 > 1 > > Total packet count:: ideal 53 lookaround 7 > > (AppleTV, 1x1 HT20) > root@cerowrt:/sys/kernel/debug/ieee80211/phy1/netdev:sw10# cat > stations/58\:55\:ca\:51\:b5\:4b/rc_stats > rate throughput ewma prob this prob this succ/attempt success > attempts > 6 3.5 57.8 100.0 0( 0) 6 > 6 > 9 3.9 43.7 100.0 0( 0) 2 > 2 > 12 5.1 43.7 100.0 0( 0) 2 > 2 > 18 10.0 57.8 100.0 0( 0) 3 > 3 > D 24 13.1 57.8 100.0 0( 0) 3 > 3 > C 36 14.2 43.7 100.0 0( 0) 2 > 2 > B 48 18.2 43.7 100.0 0( 0) 2 > 2 > A P 54 46.2 99.9 100.0 1( 1) 348 > 367 > > Total packet count:: ideal 331 lookaround 37 > > Whereas what I'm seeing for the 2.4GHz radio is: > > root@cerowrt:/sys/kernel/debug/ieee80211/phy0/netdev:sw00/stations# cat > 10\:9a\:dd\:30\:96\:34/rc_stats > type rate throughput ewma prob this prob retry this > succ/attempt success attempts > CCK/LP 1.0M 0.7 100.0 100.0 0 > 0( 0) 2 2 > CCK/SP 2.0M 0.0 0.0 0.0 0 > 0( 0) 0 0 > CCK/SP 5.5M 0.0 0.0 0.0 0 > 0( 0) 0 0 > CCK/SP 11.0M 0.0 0.0 0.0 0 > 0( 0) 0 0 > HT20/LGI MCS0 5.6 100.0 100.0 1 > 0( 0) 2 2 > HT20/LGI MCS1 0.0 0.0 0.0 0 > 0( 0) 0 0 > HT20/LGI MCS2 0.0 0.0 0.0 0 > 0( 0) 0 0 > HT20/LGI MCS3 0.0 0.0 0.0 0 > 0( 0) 0 0 > HT20/LGI MCS4 0.0 0.0 0.0 0 > 0( 0) 0 0 > HT20/LGI MCS5 30.3 100.0 100.0 5 > 0( 0) 1 1 > HT20/LGI t MCS6 32.5 100.0 100.0 5 > 0( 0) 11 11 > HT20/LGI T P MCS7 35.0 100.0 100.0 5 > 6( 6) 34 34 > > Total packet count:: ideal 45 lookaround 3 > Average A-MPDU length: 1.3 > > > And here are radio blocks from the current /etc/config/wireless: > > config wifi-device 'radio1' > option type 'mac80211' > option macaddr '28:c6:8e:bb:9a:49' > list ht_capab 'SHORT-GI-40' > list ht_capab 'TX-STBC' > list ht_capab 'RX-STBC1' > list ht_capab 'DSSS_CCK-40' > option txpower '17' > option distance '25' > option channel '48' > option country 'US' > > config wifi-device 'radio0' > option type 'mac80211' > option hwmode '11ng' > option macaddr '28:c6:8e:bb:9a:47' > option htmode 'HT20' > list ht_capab 'SHORT-GI-40' > list ht_capab 'TX-STBC' > list ht_capab 'RX-STBC1' > list ht_capab 'DSSS_CCK-40' > option txpower '26' > option country 'FR' > option distance '15' > option channel 'auto' > > =3D=3D=3D=3D=3D=3D > > Some notes after having repaired the situation: > > - The pci paths to the radios was missing from /etc/config/wireless, that= 's > the only thing that I saw that seemed grossly out of place. > > - Back up and running, and yes, it's much happier, now. Over wifi I get > 60-70Mbps upload and ~40Mbps download (running rrul). Latency sucks. Wi= fi > has some ugly bufferbloat. (although these results are somewhat in quest= ion > when the router has a 1m load average over 5.0...) > > - Enabling all the SQM features I was having previously also considerably > cleaned up wifi performance. It's more balanced, but still not nearly as > balanced as I see on gigabit ethernet. > > > > -Aaron > > _______________________________________________ > Cerowrt-devel mailing list > Cerowrt-devel@lists.bufferbloat.net > https://lists.bufferbloat.net/listinfo/cerowrt-devel > --=20 Dave T=E4ht Fixing bufferbloat with cerowrt: http://www.teklibre.com/cerowrt/subscribe.= html