From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mout.gmx.net (mout.gmx.net [212.227.15.19]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "mout.gmx.net", Issuer "TeleSec ServerPass DE-1" (verified OK)) by huchra.bufferbloat.net (Postfix) with ESMTPS id 7094221F502 for ; Sat, 25 Jul 2015 11:47:19 -0700 (PDT) Received: from hms-beagle.home.lan ([217.237.70.193]) by mail.gmx.com (mrgmx002) with ESMTPSA (Nemesis) id 0McmS9-1ZaKFG2gVd-00HtbL; Sat, 25 Jul 2015 20:47:15 +0200 Content-Type: multipart/mixed; boundary="Apple-Mail=_C67EFDB7-D671-4EE6-8906-78136512BD2D" Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) From: Sebastian Moeller In-Reply-To: <1437845902806.eb7f6ec8@Nodemailer> Date: Sat, 25 Jul 2015 20:47:09 +0200 Message-Id: <9039450E-CDB9-41D0-BACF-4B72FAC98D6D@gmx.de> References: <4D4A16C4-46C4-4910-B13F-86B6C658E5E2@gmx.de> <1437845902806.eb7f6ec8@Nodemailer> To: Alec Robertson X-Mailer: Apple Mail (2.1878.6) X-Provags-ID: V03:K0:kbg9vQGqxjUd1q8baGMp3HEr0azMOhUxtxA+Kl0mj4EWcoPHCJO CrBBmQnWW4I7QcJxGD770zW+OqHRiikc5/Tf+SbvQBXPX8YP8ItrpuJxJSoS6FBitk/E790 KyX8swowxMSLT5n0JZ8ugKqS5cJaPRPD95niNj06OE3z96nrDq/Q4Yxop3V5t4K4y80W2Dv vqbBIB4F9t3Kt6bfSPEiw== X-UI-Out-Filterresults: notjunk:1;V01:K0:Y28mEHmoQCU=:2wtEuumX/EfvPKjQekC/Ba Zr4r5Pf+01/u1j3abIltDN+zoxKwVLjbZOKK+oTzKH4AzxgSQnQRQTdJhzWYdbcZwvBg9KKb3 h6fnOrq0VdRj2wNCP/18ssejO/W0SgdDzV4Dzl7d+On/UACSAliVhFOQAbAtytKwgByo/HvZl zw4pANQz551mQi+1etV72ffHG2cgTIEDWyDFmvmh1WMU8NZg++VqsS5SwF/q7gwErVQk17n5v FoFLiD8+PYYfAF2rfsULbiFCMWmtP+PZTyKwzCutQ3DvlXe/1SZi2r2lEQPiIwMajnKPVU5z3 I+CNevXXr13SMQoYJXD5psRjU8cMLVxXMBBmP+OgoPGcfArP6d00S0ow3RzFTJZ8hbC1zggjt PoDWtcqbzdTvBTcVnxCNPfjxQd5MRQ5Y1xpjpJdqljykJb27GH7JhN1rfrKFnc1pTRn5bjep6 4tcvRPqEPkGrr9zDR7WKcJXXXrHj/f/quc+5sMAC6eaWqBRHSp/TVodfFlk5WZaVzcjvJPn0e tFEEUCh2C7gSYmTi+XHtuTKiZbQVIFccrTdp4U1gDH1Qzo5WmYjU+riGGTBZ1Hwe05fbGqCHM NZVJjlTTov5dN0+MbViG9z/c2N9/sRRAhSAmb+61wHB7SOkU8jsQCtsjGBxFtSYpUiCio7T6B ODIfOINVYPxK57Zo8Yz9tSDv9+JGRsPhGdtCCGSoGT3TYgQ== Cc: cake@lists.bufferbloat.net Subject: Re: [Cake] How to test Cake on TP-Link WDR3600 X-BeenThere: cake@lists.bufferbloat.net X-Mailman-Version: 2.1.13 Precedence: list List-Id: Cake - FQ_codel the next generation List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 25 Jul 2015 18:47:48 -0000 --Apple-Mail=_C67EFDB7-D671-4EE6-8906-78136512BD2D Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=windows-1252 Hi Alec, On Jul 25, 2015, at 19:38 , Alec Robertson = wrote: > I=92ve uploaded all the files to the router and rebooted and very = oddly, =93cake" doesn=92t show up as a qdisc but =93layer_cake.qos=94 = and =93piece_of_cake.qos=94 show up as Queue setup scripts. Ah, this just shows that your sqm.lua is older than I assumed. = No big issue just replace the /usr/lib/lua/luci/model/cbi/sqm.lua on = your router with the attached sqm.lua. That should fix that issue.=20 Then please select cake as =93Queueing discipline=94 and = piece_of_cake.qos as =93Queue setup script=94, also make sure to go to = the =93Link Layer Adaptation=94 tab and select Ethernet=85 as =93Which = link layer to account for:=94 and put in probably 8 as =93Per Packet = Overhead (byte):=94 (not quite sure what the correct value is for your = ISP), AND check the checkbox named =93Show Advanced Linklayer Options, = (only needed if MTU > 1500). Advanced options will only be used as long = as this box is checked.=94 and finally select cake as =93Which linklayer = adaptation mechanism to use; for testing only=94. That should get you = started. Most likely your firmware will not fully allow to specify = overhead for cake, but we will diagnose this and the revert to fix this = up then most likely is to select tc_stab as =93Which linklayer = adaptation mechanism to use; for testing only=94. With a bit of luck this is all that is needed to get you going. Best Regards Sebastian --Apple-Mail=_C67EFDB7-D671-4EE6-8906-78136512BD2D Content-Disposition: attachment; filename=sqm.lua Content-Type: application/octet-stream; name="sqm.lua" Content-Transfer-Encoding: 7bit --[[ LuCI - Lua Configuration Interface Copyright 2014 Steven Barth Copyright 2014 Dave Taht Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 $Id$ ]]-- local wa = require "luci.tools.webadmin" local fs = require "nixio.fs" local net = require "luci.model.network".init() local sys = require "luci.sys" --local ifaces = net:get_interfaces() local ifaces = sys.net:devices() local path = "/usr/lib/sqm" m = Map("sqm", translate("Smart Queue Management"), translate("With SQM you " .. "can enable traffic shaping, better mixing (Fair Queueing)," .. " active queue length management (AQM) " .. " and prioritisation on one " .. "network interface.")) s = m:section(TypedSection, "queue", translate("Queues")) s:tab("tab_basic", translate("Basic Settings")) s:tab("tab_qdisc", translate("Queue Discipline")) s:tab("tab_linklayer", translate("Link Layer Adaptation")) s.addremove = true -- set to true to allow adding SQM instances in the GUI s.anonymous = true -- BASIC e = s:taboption("tab_basic", Flag, "enabled", translate("Enable this SQM instance.")) e.rmempty = false -- sm: following jow's advise, be helpful to the user and enable -- sqm's init script if even a single sm instance/interface -- is enabled; this is unexpected in that the init script gets -- enabled as soon as at least one sqm instance is enabled -- and that state is saved, so it does not require "Save & Apply" -- to effect the init scripts. -- the implementation was inpired/lifted from -- https://github.com/openwrt/luci/blob/master/applications/luci-app-minidlna/luasrc/model/cbi/minidlna.lua function e.write(self, section, value) if value == "1" then luci.sys.init.enable("sqm") m.message = translate("The SQM GUI has just enabled the sqm initscript on your behalf. Remember to disable the sqm initscript manually under System Startup menu in case this change was not wished for.") -- luci.sys.call("/etc/init.d/sqm start >/dev/null") -- else -- luci.sys.call("/etc/init.d/sqm stop >/dev/null") -- luci.sys.init.disable("sqm") end return Flag.write(self, section, value) end -- TODO: inform the user what we just did... n = s:taboption("tab_basic", ListValue, "interface", translate("Interface name")) -- sm lifted from luci-app-wol, the original implementation failed to show pppoe-ge00 type interface names for _, iface in ipairs(ifaces) do -- if iface:is_up() then -- n:value(iface:name()) -- end if iface ~= "lo" then n:value(iface) end end n.rmempty = false dl = s:taboption("tab_basic", Value, "download", translate("Download speed (kbit/s) (ingress) set to 0 to selectively disable ingress shaping:")) dl.datatype = "and(uinteger,min(0))" dl.rmempty = false ul = s:taboption("tab_basic", Value, "upload", translate("Upload speed (kbit/s) (egress) set to 0 to selectively disable egress shaping:")) ul.datatype = "and(uinteger,min(0))" ul.rmempty = false -- QDISC c = s:taboption("tab_qdisc", ListValue, "qdisc", translate("Queueing discipline")) c:value("fq_codel", "fq_codel ("..translate("default")..")") c:value("efq_codel") c:value("nfq_codel") c:value("sfq") c:value("codel") c:value("ns2_codel") c:value("pie") c:value("sfq") c:value("cake") c.default = "fq_codel" c.rmempty = false local qos_desc = "" sc = s:taboption("tab_qdisc", ListValue, "script", translate("Queue setup script")) for file in fs.dir(path) do if string.find(file, ".qos$") then sc:value(file) end if string.find(file, ".qos.help$") then fh = io.open(path .. "/" .. file, "r") qos_desc = qos_desc .. "

" .. file:gsub(".help$", "") .. ":
" .. fh:read("*a") .. "

" end end sc.default = "simple.qos" sc.rmempty = false sc.description = qos_desc ad = s:taboption("tab_qdisc", Flag, "qdisc_advanced", translate("Show and Use Advanced Configuration. Advanced options will only be used as long as this box is checked.")) ad.default = false ad.rmempty = true squash_dscp = s:taboption("tab_qdisc", ListValue, "squash_dscp", translate("Squash DSCP on inbound packets (ingress):")) squash_dscp:value("1", "SQUASH") squash_dscp:value("0", "DO NOT SQUASH") squash_dscp.default = "1" squash_dscp.rmempty = true squash_dscp:depends("qdisc_advanced", "1") squash_ingress = s:taboption("tab_qdisc", ListValue, "squash_ingress", translate("Ignore DSCP on ingress:")) squash_ingress:value("1", "Ignore") squash_ingress:value("0", "Allow") squash_ingress.default = "1" squash_ingress.rmempty = true squash_ingress:depends("qdisc_advanced", "1") iecn = s:taboption("tab_qdisc", ListValue, "ingress_ecn", translate("Explicit congestion notification (ECN) status on inbound packets (ingress):")) iecn:value("ECN", "ECN ("..translate("default")..")") iecn:value("NOECN") iecn.default = "ECN" iecn.rmempty = true iecn:depends("qdisc_advanced", "1") eecn = s:taboption("tab_qdisc", ListValue, "egress_ecn", translate("Explicit congestion notification (ECN) status on outbound packets (egress).")) eecn:value("NOECN", "NOECN ("..translate("default")..")") eecn:value("ECN") eecn.default = "NOECN" eecn.rmempty = true eecn:depends("qdisc_advanced", "1") ad2 = s:taboption("tab_qdisc", Flag, "qdisc_really_really_advanced", translate("Show and Use Dangerous Configuration. Dangerous options will only be used as long as this box is checked.")) ad2.default = false ad2.rmempty = true ad2:depends("qdisc_advanced", "1") ilim = s:taboption("tab_qdisc", Value, "ilimit", translate("Hard limit on ingress queues; leave empty for default.")) -- ilim.default = 1000 ilim.isnumber = true ilim.datatype = "and(uinteger,min(0))" ilim.rmempty = true ilim:depends("qdisc_really_really_advanced", "1") elim = s:taboption("tab_qdisc", Value, "elimit", translate("Hard limit on egress queues; leave empty for default.")) -- elim.default = 1000 elim.datatype = "and(uinteger,min(0))" elim.rmempty = true elim:depends("qdisc_really_really_advanced", "1") itarg = s:taboption("tab_qdisc", Value, "itarget", translate("Latency target for ingress, e.g 5ms [units: s, ms, or us]; leave empty for automatic selection, put in the word default for the qdisc's default.")) itarg.datatype = "string" itarg.rmempty = true itarg:depends("qdisc_really_really_advanced", "1") etarg = s:taboption("tab_qdisc", Value, "etarget", translate("Latency target for egress, e.g. 5ms [units: s, ms, or us]; leave empty for automatic selection, put in the word default for the qdisc's default.")) etarg.datatype = "string" etarg.rmempty = true etarg:depends("qdisc_really_really_advanced", "1") iqdisc_opts = s:taboption("tab_qdisc", Value, "iqdisc_opts", translate("Advanced option string to pass to the ingress queueing disciplines; no error checking, use very carefully.")) iqdisc_opts.rmempty = true iqdisc_opts:depends("qdisc_really_really_advanced", "1") eqdisc_opts = s:taboption("tab_qdisc", Value, "eqdisc_opts", translate("Advanced option string to pass to the egress queueing disciplines; no error checking, use very carefully.")) eqdisc_opts.rmempty = true eqdisc_opts:depends("qdisc_really_really_advanced", "1") -- LINKLAYER ll = s:taboption("tab_linklayer", ListValue, "linklayer", translate("Which link layer to account for:")) ll:value("none", "none ("..translate("default")..")") ll:value("ethernet", "Ethernet with overhead: select for e.g. VDSL2.") ll:value("atm", "ATM: select for e.g. ADSL1, ADSL2, ADSL2+.") -- ll:value("adsl") -- reduce the options ll.default = "none" po = s:taboption("tab_linklayer", Value, "overhead", translate("Per Packet Overhead (byte):")) po.datatype = "and(integer,min(-1500))" po.default = 0 po.isnumber = true po.rmempty = true po:depends("linklayer", "ethernet") -- po:depends("linklayer", "adsl") po:depends("linklayer", "atm") adll = s:taboption("tab_linklayer", Flag, "linklayer_advanced", translate("Show Advanced Linklayer Options, (only needed if MTU > 1500). Advanced options will only be used as long as this box is checked.")) adll.rmempty = true adll:depends("linklayer", "ethernet") -- adll:depends("linklayer", "adsl") adll:depends("linklayer", "atm") smtu = s:taboption("tab_linklayer", Value, "tcMTU", translate("Maximal Size for size and rate calculations, tcMTU (byte); needs to be >= interface MTU + overhead:")) smtu.datatype = "and(uinteger,min(0))" smtu.default = 2047 smtu.isnumber = true smtu.rmempty = true smtu:depends("linklayer_advanced", "1") stsize = s:taboption("tab_linklayer", Value, "tcTSIZE", translate("Number of entries in size/rate tables, TSIZE; for ATM choose TSIZE = (tcMTU + 1) / 16:")) stsize.datatype = "and(uinteger,min(0))" stsize.default = 128 stsize.isnumber = true stsize.rmempty = true stsize:depends("linklayer_advanced", "1") smpu = s:taboption("tab_linklayer", Value, "tcMPU", translate("Minimal packet size, MPU (byte); needs to be > 0 for ethernet size tables:")) smpu.datatype = "and(uinteger,min(0))" smpu.default = 0 smpu.isnumber = true smpu.rmempty = true smpu:depends("linklayer_advanced", "1") lla = s:taboption("tab_linklayer", ListValue, "linklayer_adaptation_mechanism", translate("Which linklayer adaptation mechanism to use; for testing only")) lla:value("cake") lla:value("htb_private") lla:value("tc_stab", "tc_stab ("..translate("default")..")") lla.default = "tc_stab" lla.rmempty = true lla:depends("linklayer_advanced", "1") -- PRORITIES? return m --Apple-Mail=_C67EFDB7-D671-4EE6-8906-78136512BD2D Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=windows-1252 >=20 > Weird. >=20 > -- > Alec Robertson >=20 >=20 > On Sat, Jul 25, 2015 at 6:15 PM, Sebastian Moeller = wrote: >=20 > Hi Alec,=20 >=20 >=20 > On Jul 25, 2015, at 18:49 , Alec Robertson = wrote:=20 >=20 > > Well I've already got confused and we haven't even started yet - my = apologies.=20 >=20 > Then we are off to a good start ;)=20 >=20 > >=20 > > When you say "...select cake as qdisc and piece_of_cake.qos as = script..." how exactly do you do that?=20 >=20 > Ah, this requires luci-app-sqm, you might be able to install this from = the router=92s GUI or it might be installed already; there should be a = SQM tab in the network menu and there you should be able to configure = things. http://wiki.openwrt.org/doc/howto/sqm has some advice about how = to set things up. Please have a look and let me know what specific = questions arise ;)=20 >=20 > Best Regards=20 > Sebastian=20 >=20 >=20 > >=20 > > Again I'm sorry if I'm being silly! :P=20 > >=20 > >=20 > > Yours sincerely,=20 > > Alec Robertson.=20 > >=20 > > On 25 July 2015 at 17:27, Sebastian Moeller wrote:=20= > > Hi Alec,=20 > >=20 > > On Jul 25, 2015, at 17:45 , Alec Robertson = wrote:=20 > >=20 > > > Hello,=20 > > >=20 > > > I=92ve flashed the OpenWRT image for the TP-Link WDR3600 from = 2015-06-23 (http://snapon.lab.bufferbloat.net/~cero3/lupin/ar71xx/) and = it has installed correctly.=20 > > >=20 > > > How do I go about setting it up for my UK TalkTalk Fibre = connection (using a VDSL modem connected to the TP-Link router: the = TP-Link router gets an IP address via DHCP).=20 > > >=20 > > > My sincere apologies if any of this is really obvious and I=92ve = been silly and missed it.=20 > >=20 > > Maybe try luci-app-sqm and sqm scripts?=20 > > Attached you will find the most recent files for sqm-scripts, just = move all the files in the archive to the corresponding locations on your = router and the select cake as qdisc and piece_of_cake.qos as script. = (You might need a more recent luck-app-sqm, but first try what happens = if you try the new scripts). After using the GUI to properly configure = your interface you can always run either:=20 > > /etc/init.d/sqm stop=20 > > or=20 > > /etc/init.d/sqm start=20 > > to stop and start sqm-scripts manually. Running:=20 > > tc -d qdisc=20 > > should give you some feedback whether things worked as you intended. = If you want to tests this I am happy to help you along the way, just = holler where things break ;).=20 > >=20 > > Best Regards=20 > > Sebastian=20 > >=20 > >=20 > > >=20 > > >=20 > > > =97=20 > > > Alec Robertson=20 > > > _______________________________________________=20 > > > Cake mailing list=20 > > > Cake@lists.bufferbloat.net=20 > > > https://lists.bufferbloat.net/listinfo/cake=20 > >=20 > >=20 > >=20 > > _______________________________________________=20 > > Cake mailing list=20 > > Cake@lists.bufferbloat.net=20 > > https://lists.bufferbloat.net/listinfo/cake=20 >=20 >=20 >=20 > _______________________________________________ > Cake mailing list > Cake@lists.bufferbloat.net > https://lists.bufferbloat.net/listinfo/cake --Apple-Mail=_C67EFDB7-D671-4EE6-8906-78136512BD2D--