[GCC 7.2 BUILD] Optimized TP-Link Archer C7 V2 AC1750 LEDE Firmware

hey i fixed the softirq issue, because of what i read here:

so i added this to my sysctl.conf:

net.ipv4.tcp_rmem = 10240 87380 12582912
net.ipv4.tcp_wmem = 10240 87280 12582912
net.core.rmem_max = 12582912
net.core.wmem_max = 12582912

let me know what you think! i also added irqbalancer to the kernel image, but didnt notice anything until the sysctl change.

How did you calculate those values?

Also in the link you provided there is this quote:

I doubled the values of net.ipv4.tcp_mem and that didn't seem to make any impact. Seeing about 40K dropped packets every second.

And the solution is this:

The way to fix this is to set an explicit TCP buffer size when using rate control to prevent this aberrant behavior.

Too bad I have no idea what he's talking about.

This has been said a lot of times before, SQM and Fast Classifier are mutually exclusive, you must choose one but not both, you can find a technical explanation in the forum (I don't want to repeat it here).
Flow offload seems that is compatible with SQM (or the developers are making efforts to make it work) so that's the future.

Hi I really like your build and have been using it as a daily driver for the past 5 months.
I recently switched over to Cloudflare DNS ( by inputing it into DNS forwarding via LuCI web interface.
Cloudflare DNS mentions that it supports DNS over HTTPS. Is this the same as DNSCrypt? if so how would I make sure it is being used with Cloudflare DNS and if not how can I enable DNS over HTTPS (DoH) on this build? Im kind of a noob to this but I am comfortable with SSHing into the router and using the terminal.

Cloudflare themselves have instructions for how to do it over TLS.

Seeing this I have enabled it on my pfSense router as that already was using Unbound for full resolution so just adding the bit to forward to Cloudflare instead was trivial.

Hi there. I am currently running December (or maybe even November?) stable build by @r00t . I now have 500/100Mbit internet connection and I can only get around 300Mbps (wired obviously). I can get full speed by connecting my PC directly to the modem, however running everything through my router seems like a better option.
I know such speeds are hard to reach without NW NAT, yet there seem to have been some developments recently. I am referring mainly to Fast Path and some users reporting significantly better speeds with it. I found builds supposedly including it here. I was wondering if I can just sysupgrade to that and what my other options are. What about @sycohexor's builds?
Btw, I want to skip breed BL for now.


Ok, nice im not sure how I missed that, ill try it out right now. Im guessing that DNSCrypt specifically is only supported by OpenDNS

This is an interesting read https://tenta.com/blog/post/2017/12/dns-over-tls-vs-dnscrypt

1 Like

i dont think you really need breed for my build, when i was at normal clock speeds i still got the extra boost, even with fast classifier disabled i think my builds still get the same speeds.

Thanks for the info. Will install once I have more time and report back in your thread.

Having flashed my router with this build (thnx, root and others), I'm finally getting to use a usb hdd. I've plugged the drive in, but it doesn't show in at the terminal output:


nor do I see it in the webgui at mountpoints. Syslog shows it as there.

root@c7main:/# uname -r
root@c7main:/# cat /etc/openwrt_*

what does the command df show?

This is a stock, [GCC 7.2] build. Other than adding VPN ware, nothing is altered.

After opkg update

root@c7main:~# opkg install kmod-fs-ext4
Upgrading kmod-fs-ext4 on root from 4.9.67-1 to 4.9.91-1...
Downloading http://downloads.lede-project.org/snapshots/targets/ar71xx/generic/packages/kmod-fs-ext4_4.9.91-1_mips_24kc.ipk
Collected errors:
 * satisfy_dependencies_for: Cannot satisfy the following dependencies for kmod-fs-ext4:
 * 	kernel (= 4.9.91-1-32f977e15ddea593ee4fcb1dca2e5862) * 
 * opkg_install_cmd: Cannot install package kmod-fs-ext4.
root@c7main:~# opkg install kmod-usb-storage-extras
Upgrading kmod-usb-storage-extras on root from 4.9.67-1 to 4.9.91-1...
Downloading http://downloads.lede-project.org/snapshots/targets/ar71xx/generic/packages/kmod-usb-storage-extras_4.9.91-1_mips_24kc.ipk
Collected errors:
 * satisfy_dependencies_for: Cannot satisfy the following dependencies for kmod-usb-storage-extras:
 * 	kernel (= 4.9.91-1-32f977e15ddea593ee4fcb1dca2e5862) * 
 * opkg_install_cmd: Cannot install package kmod-usb-storage-extras.

Hey everyone. For those wanting to use cloudflare DNS encrypted, you can also use stubby. (Package is in master, so you may need to adjust your package feeds.)

opkg update
opkg install stubby

Note: the default package config uses quad9, but this can be changed to use cloudflare.

1 Like

this is the best i can get from windows to router wired with gb nic:

[ ID] Interval           Transfer     Bandwidth
[  4]   0.00-1.01   sec  25.0 MBytes   208 Mbits/sec
[  4]   1.01-2.01   sec  28.1 MBytes   236 Mbits/sec
[  4]   2.01-3.01   sec  28.5 MBytes   239 Mbits/sec
[  4]   3.01-4.00   sec  24.8 MBytes   209 Mbits/sec
[  4]   4.00-5.00   sec  26.2 MBytes   220 Mbits/sec
[  4]   5.00-6.00   sec  25.1 MBytes   211 Mbits/sec
[  4]   6.00-7.00   sec  27.8 MBytes   233 Mbits/sec
[  4]   7.00-8.00   sec  24.4 MBytes   204 Mbits/sec
[  4]   8.00-9.01   sec  26.2 MBytes   219 Mbits/sec
[  4]   9.01-10.00  sec  23.8 MBytes   200 Mbits/sec
- - - - - - - - - - - - - - - - - - - - - - - - -
[ ID] Interval           Transfer     Bandwidth
[  4]   0.00-10.00  sec   260 MBytes   218 Mbits/sec                  sender
[  4]   0.00-10.00  sec   260 MBytes   218 Mbits/sec                  receiver

iperf Done.

Could a package be added to this build in the future for DNS over TLS?

I'm not sure, but my guess would be no. I'm not sure what the process is to get packages backported. If someone does, I would be willing to try. However, with a new build of openwrt on the horizon, I'm sure the devs are more focused on getting that buttoned up vs. accepting backports.

Hi, I'm trying to use the Archer C7 v4 on a 1Gbps connection.

I've read the LEDE threads and I understand the options are:

  1. Qualcomm FastPath -- included in the LEDE Optimized Firmware and also here
  2. Flow Offload -- this is not an option since it's only available on kernel 4.14 and current kernel is 4.9. Performance is similar to FastPath, so no need to consider this, just patiently wait.
  3. Hardware-based NAT -- based on this discussion, use the ar71xx MIPS24k patches.
    Note: On a closer look, these patches are essentially FastPath, therefore hardware-based NAT is only available in stock firmware.

It strikes me though as interesting that the guy who built the LEDE optimized firmware for Archer C7 v2 although he included in his list of changes both hardware-based NAT and Qualcomm Fast Path, there's no mention of the hardware-based NAT in his summary of changes. Maybe ended up not using it or maybe FastPath was initially mislabelled as hardware-based NAT.

I have also NOT seen any performance results on the Archer C7. One reported result with h/w-based NAT actually shows performance degradation and the original post author hinted at other factors affecting LEDE performance outside the NAT piece. On this post, there's these - unsupported by results - comments:

LAN to LAN is 1gbps for sure. Wan to LAN is about 450-500 without hw Nat which is marginally meet your requirements.
Or you use community build with hw nat enabled, 700-800.

c7 with fastpath will do ~930 mb/s nat on static/dhcp ip and ~650mb/s on pppoe

Any thoughts?

1 Like

The only way to have Hardware NAT enabled is to use the stock TP-Link firmware, that's why FastPath/Offload are the only options for now.

LAN to LAN: you get stock speeds, no NAT involved here, just the switch.
LAN to WAN: using fastpath or offload you get close to 1Gbps. Shapping not compatible so no SQM.
PPPOE: not compatible with fastpath, that's why the speed drop (this has been reported in this forum)

Now, my personal use case, I have a wan connection < 300Mbps, so I unload the fastpath module and enable SQM Cake/piece_of_cake to reduce bufferbloat.

Btw, if you have a 1Gbps wan connection I recommend to buy a better router, even with the TP-Link stock firmware you will have slowdowns.

1 Like

I recommend you to buy an x86/x64 Fanless PC like:

Install OpenWRT/LEDE and forget the rest of options.

I'm using a Fanless PC as router very similar to the one linked before (running LEDE + SQM + VPN IPSEC + Luci +....) and after 6 six months using it, my performance "problems" are over forever.
My old C7 v2 now is working as dumb AP (running OpenWRT).