OpenWrt Forum Archive

Topic: Update on Linksys WRT1900AC support

The content of this topic has been archived between 16 Sep 2014 and 7 May 2018. Unfortunately there are posts – most likely complete pages – missing.

I have just finished getting IPv6 working on my WRT1900AC and tried iperf to my Mythbuntu box to see how well it was working.  I was surprised to see that the IPv6 performance is much less than for IPv4:

 [root@wrt1900ac /etc/config]# iperf -c 10.0.2.4
------------------------------------------------------------
Client connecting to 10.0.2.4, TCP port 5001
TCP window size: 43.8 KByte (default)
------------------------------------------------------------
[  3] local 10.0.2.249 port 38760 connected with 10.0.2.4 port 5001
[ ID] Interval       Transfer     Bandwidth
[  3]  0.0-10.0 sec  1.08 GBytes   929 Mbits/sec


 [root@wrt1900ac /etc/config]# iperf -V -c 2406:e001:1:2802::4
------------------------------------------------------------
Client connecting to 2406:e001:1:2802::4, TCP port 5001
TCP window size: 43.8 KByte (default)
------------------------------------------------------------
[  3] local 2406:e001:1:2802::249 port 43964 connected with 2406:e001:1:2802::4 port 5001
[ ID] Interval       Transfer     Bandwidth
[  3]  0.0-10.0 sec   656 MBytes   550 Mbits/sec

I do not see the same thing when using iperf from my mother's Mythbuntu box to the same server:

root@crw-pvr:/etc# iperf -V -c mypvr.6.jsw.gen.nz
------------------------------------------------------------
Client connecting to mypvr.6.jsw.gen.nz, TCP port 5001
TCP window size: 85.0 KByte (default)
------------------------------------------------------------
[  3] local 2406:e001:1:2802::8 port 55079 connected with 2406:e001:1:2802::4 port 5001
[ ID] Interval       Transfer     Bandwidth
[  3]  0.0-10.0 sec  1.08 GBytes   930 Mbits/sec

Does anyone have any idea what the problem might be?

@nitroshift
could I inquire about the progress of the hardware accelerated encryption project you were working on?

Thanks!

Is there a wiki that explains how OpenWRT applies iptables on the backend, and if not, could someone please point me in the right direction on where I could find more information about how OpenWRT applies iptables?

The reason:

I'd like to setup the same firewall I have on my WRT 1900ac on my Netgear R6300 running DD-WRT.

I can manually copy every rule in command form and create a script, but I'd prefer not to if there was a way I could implement the same command script OpenWRT uses for iptables on the backend.  I've taken a look at the firewall wiki OpenWrt Firewall, however it doesn't describe how OpenWRT runs iptables on the backend

(Last edited by JW0914 on 5 May 2015, 15:30)

JW0914 wrote:

Is there a wiki that explains how OpenWRT applies iptables on the backend, and if not, could someone please point me in the right direction on where I could find more information about how OpenWRT applies iptables?

This has almost nothing to do with specifically about wrt190ac, but I will answer in any case...
Openwrt reads the config in "uci" format from /etc/config/firewall . "firewall3" is the current firewall program and its c sources are in http://nbd.name/gitweb.cgi?p=firewall3.git;a=tree
That firewall3 generates the iptables rules from the uci config and applies them.
I think that you can print the actual rules with "fw3 print".

(Last edited by hnyman on 5 May 2015, 15:36)

fe31nz wrote:

I have just finished getting IPv6 working on my WRT1900AC and tried iperf to my Mythbuntu box to see how well it was working.  I was surprised to see that the IPv6 performance is much less than for IPv4:
...
Does anyone have any idea what the problem might be?

Those speeds are similar to what nitroshift has reported switching his WAN connection between plain Ethernet and PPPoE. That, in turn, might be the difference between a protocol that the Ethernet chip can checksum (or otherwise offload) in hardware versus one done in software.

hnyman wrote:
JW0914 wrote:

Is there a wiki that explains how OpenWRT applies iptables on the backend, and if not, could someone please point me in the right direction on where I could find more information about how OpenWRT applies iptables?

This has almost nothing to do with specifically about wrt190ac, but I will answer in any case...
Openwrt reads the config in "uci" format from /etc/config/firewall . "firewall3" is the current firewall program and its c sources are in http://nbd.name/gitweb.cgi?p=firewall3.git;a=tree
That firewall3 generates the iptables rules from the config and applies them.
I think that you can print the actual rules with "fw3 print".

Thanks, I appreciate it =]

My bad, I wasn't sure where to post the question, however if you can let me know where it should be posted, I can delete it and repost it there

leitec wrote:
fe31nz wrote:

I have just finished getting IPv6 working on my WRT1900AC and tried iperf to my Mythbuntu box to see how well it was working.  I was surprised to see that the IPv6 performance is much less than for IPv4:
...
Does anyone have any idea what the problem might be?

Those speeds are similar to what nitroshift has reported switching his WAN connection between plain Ethernet and PPPoE. That, in turn, might be the difference between a protocol that the Ethernet chip can checksum (or otherwise offload) in hardware versus one done in software.

That sounds like a good theory.  I have one ethernet port from my "outer" (DMZ) subnet bridged to guest WLANs on each radio, and similarly have another ethernet port bridged from my "inner" subnet to normal WLANs on each radio.  So the firewall is doing almost nothing, and there is not much routing going on either.  That leaves checksumming as about the only other good candidate for a slowdown.  But I would have thought that the CPU was fast enough to have handled 1 gigabit traffic without a problem like that.

What I see using top is that when iperf is using IPv4, CPU usage by iperf is 14%.  For IPv6 though, it is 50%, which I presume means all of one CPU core.  I am using the iperf-mt package, but it looks like even with multithreading, iperf-mt only uses one core for a simple uni-directional test.  I would have expected checksumming to have been done in the ethernet drivers, so it is looking more like a bug in the iperf-mt IPv6 code.  So I tried iperf3, and it has exactly the same problem.  I am unfamiliar with how busybox top reports CPU usage though - could the report for the iperf process include the time spent in the ethernet drivers (and their interrupt code?).

This might sound like a dumb question and I apologize for that.. What is the purpose of openwrt_wrt1900ac_snapshot_sysupgrade.tar and how to apply to current image?

Thanks,
-JM

Juni0rM1nt wrote:

This might sound like a dumb question and I apologize for that.. What is the purpose of openwrt_wrt1900ac_snapshot_sysupgrade.tar and how to apply to current image?

Thanks,
-JM

It contains the upgraded system core system files, allowing you to upgrade those files to the current kernel version while still keeping all customizations (i.e. IP, added packages, etc).  To apply it, you can download and upload it via the gui or do it via uci by downloading it with wget.

The factory.img will erase all customizations and while you can reapply them fairly easily, it also erases all installed packages (basically a restore to default). 

In the most update sysupgrade.tar, you will get an error with with kmod-mwlwifi, stating there's a kernel mismatch (even though there's not?)

@JW0914

I appreciate your answer. Thank you.

The OpenWRT trunk in looking really good smile

I've put this in one production environment for evaluation in a AP configuration.

System
Hostname WRT5
Model Linksys WRT1900AC
Firmware Version OpenWrt Chaos Calmer r45601 / LuCI (git-15.118.50175-36879e9) 
Kernel Version 3.18.11
Local Time Tue May 5 10:03:56 2015
Uptime 13h 28m 38s
Load Average 0.00, 0.02, 0.05

JW0914 wrote:
Juni0rM1nt wrote:

This might sound like a dumb question and I apologize for that.. What is the purpose of openwrt_wrt1900ac_snapshot_sysupgrade.tar and how to apply to current image?

Thanks,
-JM

It contains the upgraded system core system files, allowing you to upgrade those files to the current kernel version while still keeping all customizations (i.e. IP, added packages, etc).  To apply it, you can download and upload it via the gui or do it via uci by downloading it with wget.

The factory.img will erase all customizations and while you can reapply them fairly easily, it also erases all installed packages (basically a restore to default). 

In the most update sysupgrade.tar, you will get an error with with kmod-mwlwifi, stating there's a kernel mismatch (even though there's not?)

Actually a sysupgrade, while you can keep your settings, IT DOES STILL wipe your custom installed packages...

Hello -

I am new to Openwrt (not to linux). Currently playing with the Wrt1900Ac Ver 1 router, encounted persistant issue with router of th 2.4 Ghz Radio
does not work after a reboot, but requires a hard power off condition for a couple of minutes before it "Might" work.  I have tried two routers and
misc versions of CHAOS CALMER (most stable was (r45590, now r45595).  Returning router to *stock* belkin-linksys stiil shows the prblem.

Love the router and openwrt, would love a solution.

Steve F

stevef9432204 wrote:

Hello -

I am new to Openwrt (not to linux). Currently playing with the Wrt1900Ac Ver 1 router, encounted persistant issue with router of th 2.4 Ghz Radio
does not work after a reboot, but requires a hard power off condition for a couple of minutes before it "Might" work.  I have tried two routers and
misc versions of CHAOS CALMER (most stable was (r45590, now r45595).  Returning router to *stock* belkin-linksys stiil shows the prblem.

Love the router and openwrt, would love a solution.

Steve F

After you uploaded the OpenWRT mamba trunk firmware did you get an IP Address from the router on your computer? If so did you use telnet to connect to the router?

After connecting to OpenWRT you will need to run the below commands:

opkg update
opkg install luci

Yes I  have done all of that.  I works fine,  just not the 2.4ghz radio. Currently working thru this router

stevef9432204 wrote:

Yes I  have done all of that.  I works fine,  just not the 2.4ghz radio. Currently working thru this router

Odd the wireless has always worked for me with Linksys and OpenWRT firmwares. Maybe the unit is defective.

alirz wrote:
JW0914 wrote:
Juni0rM1nt wrote:

This might sound like a dumb question and I apologize for that.. What is the purpose of openwrt_wrt1900ac_snapshot_sysupgrade.tar and how to apply to current image?

Thanks,
-JM

It contains the upgraded system core system files, allowing you to upgrade those files to the current kernel version while still keeping all customizations (i.e. IP, added packages, etc).  To apply it, you can download and upload it via the gui or do it via uci by downloading it with wget.

The factory.img will erase all customizations and while you can reapply them fairly easily, it also erases all installed packages (basically a restore to default). 

In the most update sysupgrade.tar, you will get an error with with kmod-mwlwifi, stating there's a kernel mismatch (even though there's not?)

Actually a sysupgrade, while you can keep your settings, IT DOES STILL wipe your custom installed packages...

@alirz

I have only the packages that came with Kaloz latest image, which include luci. After running sysupgrade.tar will I lose these default packages?

Thanks,
-JM

richbhanover wrote:
Juni0rM1nt wrote:

@nitroshit.

Can anyone compile a list of, what would be considered--essential packages to install with Kaloz latest image?

Thanks!
-JM

I keep that list in a script that I use to configure the stock OpenWrt to my liking. I flash the firmware, then telnet into the router, run the script, and Presto! It's running "right".

The script is config-openwrt.sh at http://github.com/richb-hanover/openwrtscripts

It's a work in progress - there are a bunch of other things I want to add when I get time, but it'll get you started.

Thanks for the link smile

Juni0rM1nt wrote:
alirz wrote:
JW0914 wrote:

It contains the upgraded system core system files, allowing you to upgrade those files to the current kernel version while still keeping all customizations (i.e. IP, added packages, etc).  To apply it, you can download and upload it via the gui or do it via uci by downloading it with wget.

The factory.img will erase all customizations and while you can reapply them fairly easily, it also erases all installed packages (basically a restore to default). 

In the most update sysupgrade.tar, you will get an error with with kmod-mwlwifi, stating there's a kernel mismatch (even though there's not?)

Actually a sysupgrade, while you can keep your settings, IT DOES STILL wipe your custom installed packages...

@alirz

I have only the packages that came with Kaloz latest image, which include luci. After running sysupgrade.tar will I lose these default packages?

Thanks,
-JM

If you flash the daily snapshot build, then yes... but if you flash kaloz's sysupgrade on his page, no (unless you added custom packages yourself, at which point you'd have to reinstall those packages).

If you want to flash the snapshot build, I'd recommend setting up pivot overlay, which would eliminate having to reinstall most packages (i meant to include that in my previous post).  If you set up pivot overlay, the only packages you'd ever have to reflash would be: block-mount kmod-usb-storage-extras kmod-fs-ext4 (or whatever file system you used on your thumb drive)

ExtRoot Wiki

If you choose to do pivot overlay, the only additional steps would be

block detect > /etc/config/fstab ; vi /etc/config/fstab

and then change all the config mount or config swap 0's to 1's

Once that's done, reboot, and you should be operating off pivot overlay; at which point you need to run:

opkg update ; opkg list-upgradable

and for whichever ones need to be upgraded

opkg upgrade package1 package2 pacakge3

(Last edited by JW0914 on 5 May 2015, 21:27)

Chadster766 wrote:

The OpenWRT trunk in looking really good smile

Yep...

(Last edited by gufus on 6 May 2015, 00:03)

gufus wrote:
Chadster766 wrote:

The OpenWRT trunk in looking really good smile

Yep...

I've put this in a second production environment for evaluation in an AP configuration.

Note:
For a test I set the 5Ghz to 160Mhz channel width. It caused the 5Ghz to be set as "Client" instead of "Master" disabling the 5Ghz.

Chadster766 wrote:
gufus wrote:
Chadster766 wrote:

The OpenWRT trunk in looking really good smile

Yep...

I've put this in a second production environment for evaluation in an AP configuration.

Note:
For a test I set the 5Ghz to 160Mhz channel width. It caused the 5Ghz to be set as "Client" instead of "Master" disabling the 5Ghz.

Maybe open a issue at https://github.com/kaloz/mwlwifi

But then again, it could be a openwrt bug.

(Last edited by gufus on 6 May 2015, 02:11)

Yup.. just tryed here and it did the same thing sad

Not sure if I'm drunk but seems wifi speed is much more stable and a bit fast under 4.0.1 kernel than 3.18.11 with all configuration setting equal.

OpenWrt Chaos Calmer r45610 / LuCI Master (git-15.125.30735-c38b4cd)
Linux Kernel: 3.18.11

Network goes down, can't access luci, hard reboot required. Since i needed the internet i didn't try to get logs.