What's new

Merlin - USB3 I/O must slower than DDWRT

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

keratos

Guest
So I have tried

Merlin .40
Merlin .41-beta1
Asus -4561

Same laptop with same card and no other clients, same setup each time.

The DDWRT f/w supports wired I/O to USB3 around 40MBps
Merlin f/w (and Asus) is more like 23MBps

Wireless writes however are slower on DDWRT (5MBps) to Asus/Merlin (8MBps)

My 802.11n 300mbps link is probably actually half that in reality, 150mbps which is around 17MBps - still way off the 8MBps I'm getting.

Not very scientific tests but repeatable and consistent using a handful of linix cmds.
 
And I was able to hit 50 MB/s with my firmware on an RT-AC68. <shrug>

A lot of environment-specific things will affect performance.
 
And I was able to hit 50 MB/s with my firmware on an RT-AC68. <shrug>

A lot of environment-specific things will affect performance.

Mate, what "environment" are you talking about - I'm refering to a wired connection using CAT6 albeit from a 10/100 (laptop) to 100/1000 (AC56U). No other clients connected, radios turned off, services shut down, verybasic stuff Merlin.

Mate, there is something wrong with your USB stack - although I'm no expert in C/C++, TCP/IP, Clib etc (see my other post on these forum). However, your USB libs are not as good - is the USB source you are using proprietary (non SDK) as in a copy of ASUS's because the USB performance is about the same as theirs - just DDWRT is faster albeit slower radio performance.

I prefer your f/w for use and simplicity - there are far too many options in DDWRT but that is never a bad thing.
 
Last edited:
10/100 laptop?

I hope you mean a Gigabit laptop.
With a 100Mb lan you can't access a drive faster than about 12MB/s.

Also have you tried disabling "reduce USB3 interference" in WiFi settings?

I think Merlin means that some HDD works well with a USB driver and not with another and vice-versa.. also there are many settings you could try to change.

Remember to use linux formatting (ext3 or ext4).

Anyway if you want a powerfull, speedy but simple to use firmware you could try Tomato (still in beta for AC68U). It has a very simple interface.. in my opinion is also simpler than AsusWRT because it has lot of option but very well organized and with basic setting at first. I'll probably try it on ac68u when stable. On my oldest Netgear WNR3500L had Toastman Tomato with incredible performances, totally stable and full of bells and whistle! AsusWRT by now is not yet solid.. every release has new bugs.. we are lucky that Merlin fixes a lot of them.. but for doing same thing as before I had to use a lot of cables because WiFi DLNA and WiFi SABA were not totally realiable.. by now only .38 seems quite usable with some patches. I'll try 0.41
 
Sorry, YES, laptop 100/1000

Ext4 was slower than Ext2 slower than FAT32

what are the "many settings" you refer to. I dont see any for the USB interface other than Disabling interference on 2.4GHz band which doesnt change anything.

Tomato not stable on AC56U.

Merlin is doing a great job, I dont have the time or inclination (I'm 48 but in my early days with RedHat 2 and Prestel (!!) I recall spending early hours of the morning recomplining the kernel and linux drivers to maximse performance. a loooong time ago.
 
So I have tried

Merlin .40
Merlin .41-beta1
Asus -4561

Same laptop with same card and no other clients, same setup each time.

The DDWRT f/w supports wired I/O to USB3 around 40MBps
Merlin f/w (and Asus) is more like 23MBps

And here are my own tests, writing (38 MB/s) and reading (50 MB/s) a 1.5 GB file to prove that the firmware has no problem beating DD-WRT there. This is why I'm saying this is an environment thing, since the same firmware yields different results - something is different in your setup to explain why your performance is so low. It's not a firmware limitation.
 

Attachments

  • read.png
    read.png
    8.9 KB · Views: 399
  • write.png
    write.png
    8.9 KB · Views: 284
Last edited:
I will have to check the linux USB and Networking stack on my MINT Petra 16 build. I might install Arch linux as this had limited bloatwsre and more targeted at better h/w
My lappy is 8gb RAM , decent GEforce , quad core i7, 7200 WD DMA HDD... And so on. I don't get it. But then again why would DDWRT run far better on the same setup. This is going to take me some time...
 
I will have to check the linux USB and Networking stack on my MINT Petra 16 build. I might install Arch linux as this had limited bloatwsre and more targeted at better h/w
My lappy is 8gb RAM , decent GEforce , quad core i7, 7200 WD DMA HDD... And so on. I don't get it. But then again why would DDWRT run far better on the same setup. This is going to take me some time...

Actually, looking back at your results, it seems like your disk is mounted as a USB2 device rather than a USB3 device - that would be in line with the 25 MB/s results. Can you see in syslog that your disk gets mounted by xhci and not by ehci?

If it's mounted by ehci, make sure you do not have USB 3.0 Interference reduction enabled - this basically downgrades the USB3 port to USB2. Asus leaves this enabled by default because they think (rightly) that wireless performance/stability out of the box was more important than USB performance.
 
So I have tried

Merlin .40
Merlin .41-beta1
Asus -4561

Same laptop with same card and no other clients, same setup each time.

The DDWRT f/w supports wired I/O to USB3 around 40MBps
Merlin f/w (and Asus) is more like 23MBps

Wireless writes however are slower on DDWRT (5MBps) to Asus/Merlin (8MBps)

My 802.11n 300mbps link is probably actually half that in reality, 150mbps which is around 17MBps - still way off the 8MBps I'm getting.

Not very scientific tests but repeatable and consistent using a handful of linix cmds.
Hi,
Which dd-wrt did you try? old radio driver or new driver?
They act differently.
 
Actually, looking back at your results, it seems like your disk is mounted as a USB2 device rather than a USB3 device - that would be in line with the 25 MB/s results. Can you see in syslog that your disk gets mounted by xhci and not by ehci?

If it's mounted by ehci, make sure you do not have USB 3.0 Interference reduction enabled - this basically downgrades the USB3 port to USB2. Asus leaves this enabled by default because they think (rightly) that wireless performance/stability out of the box was more important than USB performance.

Ah-ha ! this sounds interesting. xhci is indeed the module loaded however it may be operating in low power or low compatibility mode or something. I'm no expert of the USB stack but noted a few interesting annotations in syslog:

extracts from xhci logging
Code:
Jan  1 00:00:13 kernel: xhci_hcd 0000:00:0b.0: xHCI Host Controller
Jan  1 00:00:13 kernel: xhci_hcd 0000:00:0b.0: new USB bus registered, assigned bus number 1
Jan  1 00:00:13 kernel: xhci_hcd 0000:00:0b.0: irq 112, io mem 0x18023000
Jan  1 00:00:13 kernel: xhci_hcd 0000:00:0b.0: Failed to enable MSI-X
Jan  1 00:00:13 kernel: xhci_hcd 0000:00:0b.0: failed to allocate MSI entry
Jan  1 00:00:13 kernel: [xhci-hub] usb2mode:[0]
Jan  1 00:00:13 kernel: usb 1-1: new SuperSpeed USB device using xhci_hcd and address 2
Jan  1 00:00:13 kernel: xhci_hcd 0000:00:0b.0: WARN: short transfer on control ep
Jan  1 00:00:13 kernel: xhci_hcd 0000:00:0b.0: WARN: short transfer on control ep
Jan  1 00:00:13 kernel: xhci_hcd 0000:00:0b.0: WARN: short transfer on control ep
Jan  1 00:00:13 kernel: xhci_hcd 0000:00:0b.0: WARN: short transfer on control ep
Jan  1 00:00:13 kernel: xhci_hcd 0000:00:0b.0: WARN no SS endpoint bMaxBurst
Jan  1 00:00:14 kernel: xhci_hcd 0000:00:0b.0: WARN: Stalled endpoint
Jan  1 00:00:14 kernel: xhci_hcd 0000:00:0b.0: WARN: Stalled endpoint
Jan  1 00:00:15 kernel: xhci_hcd 0000:00:0b.0: WARN: Stalled endpoint
admin@ROUTER:/tmp/home/root#

a few extracts from usb logging
Code:
admin@ROUTER:/tmp/home/root# cat /tmp/syslog.log  | grep usb
Jan  1 00:00:12 syslog: module ledtrig-usbdev not found in modules.dep
Jan  1 00:00:12 syslog: module leds-usb not fogund in modules.dep
Jan  1 00:00:13 kernel: usbcore: registered new interface driver usbfs
Jan  1 00:00:13 kernel: usbcore: registered new interface driver hub
Jan  1 00:00:13 kernel: usbcore: registered new device driver usb
Jan  1 00:00:13 kernel: usbcore: registered new interface driver usb-storage
Jan  1 00:00:13 kernel: usb usb1: No SuperSpeed endpoint companion for config 1  interface 0 altsetting 0 ep 129: using minimum values
Jan  1 00:00:13 kernel: [xhci-hub] usb2mode:[0]
Jan  1 00:00:13 kernel: usb 1-1: new SuperSpeed USB device using xhci_hcd and address 2
Jan  1 00:00:13 kernel: usbcore: registered new interface driver usblp
Jan  1 00:00:13 kernel: scsi0 : usb-storage 1-1:1.0
Jan  1 00:00:13 kernel: usbcore: registered new interface driver asix
Jan  1 00:00:13 kernel: usbcore: registered new interface driver cdc_ether
Jan  1 00:00:13 kernel: usbcore: registered new interface driver rndis_host
Jan  1 00:00:13 kernel: usbcore: registered new interface driver cdc_ncm
admin@ROUTER:/tmp/home/root#

"usb2mode:[0]" .... so port power being set - reduced power / reduced speed ??? not sure, no expert.

"Jan 1 00:00:13 kernel: usb 1-1: new SuperSpeed USB device using xhci_hcd and address 2" - does suggest USB3 attached to 2nd port though?


Code:
admin@ROUTER:/tmp/home/root# cat /tmp/usb.log
[usb_dbg: asus_usb_interface] (1-1:1.0): action=add.
[usb_dbg: asus_usb_interface] (1-1): action=add.
[usb_dbg: asus_usb_interface] (1-1): Fail to get usb node.
[usb_dbg: asus_usb_interface] (1-1:1.0): Not modem interface.
[usb_dbg: asus_sg] (sg0): action=add.
[usb_dbg: init_3g_param] 3G: Auto setting.
[usb_dbg: asus_sg] (sg0): insmod cdrom!
[usb_dbg: asus_sd] (sda): action=add.
[usb_dbg: get_usb_node_by_device] (lp0): Fail to get link: /sys/class/usb/lp0/device.
[usb_dbg: get_usb_node_by_device] (lp1): Fail to get link: /sys/class/usb/lp1/device.
[usb_dbg: get_usb_node_by_device] (lp2): Fail to get link: /sys/class/usb/lp2/device.
[usb_dbg: get_usb_node_by_device] (lp3): Fail to get link: /sys/class/usb/lp3/device.
[usb_dbg: get_usb_node_by_device] (lp4): Fail to get link: /sys/class/usb/lp4/device.
[usb_dbg: get_usb_node_by_device] (lp5): Fail to get link: /sys/class/usb/lp5/device.
[usb_dbg: get_usb_node_by_device] (lp6): Fail to get link: /sys/class/usb/lp6/device.
[usb_dbg: get_usb_node_by_device] (lp7): Fail to get link: /sys/class/usb/lp7/device.
[usb_dbg: get_usb_node_by_device] (lp8): Fail to get link: /sys/class/usb/lp8/device.
[usb_dbg: get_usb_node_by_device] (lp9): Fail to get link: /sys/class/usb/lp9/device.
[usb_dbg: asus_sd] (sda1): action=add.
[usb_dbg: get_usb_node_by_device] (lp0): Fail to get link: /sys/class/usb/lp0/device.
[usb_dbg: get_usb_node_by_device] (lp1): Fail to get link: /sys/class/usb/lp1/device.
[usb_dbg: get_usb_node_by_device] (lp2): Fail to get link: /sys/class/usb/lp2/device.
[usb_dbg: get_usb_node_by_device] (lp3): Fail to get link: /sys/class/usb/lp3/device.
[usb_dbg: get_usb_node_by_device] (lp4): Fail to get link: /sys/class/usb/lp4/device.
[usb_dbg: get_usb_node_by_device] (lp5): Fail to get link: /sys/class/usb/lp5/device.
[usb_dbg: get_usb_node_by_device] (lp6): Fail to get link: /sys/class/usb/lp6/device.
[usb_dbg: get_usb_node_by_device] (lp7): Fail to get link: /sys/class/usb/lp7/device.
[usb_dbg: get_usb_node_by_device] (lp8): Fail to get link: /sys/class/usb/lp8/device.
[usb_dbg: get_usb_node_by_device] (lp9): Fail to get link: /sys/class/usb/lp9/device.
[usb_dbg: asus_sg] (sg0): Success!
[usb_dbg: asus_sd] (sda1): Success!
[usb_dbg: asus_sd] (sda): Success!
admin@ROUTER:/tmp/home/root#

ideas? - I agree, there is something amiss with the USB hard drive. My net is fine , throughput is fine, machines are fine, the router is clearly capable of more throughput to uSB devices, so the problem must lie with the USB drive I'm using , but what/why?

how do I get logging to "xhci_dbg" as per xhci_hub.c without of course setting CCFLAGS at compile time with source which I do not have. ?? Is there a way on this router to invoke debugging ?

also, the kernel is quite old: "2.6.36.4brcmarm #1 SMP PREEMPT Sun Apr 13 13:59:58 EDT 2014 armv7l GNU/Linux"
Can we get a newer kernel Merlin with latest drivers. v2.6, sooooo old.

EDIT: Merlin, I did the following which has lifted transfer to USB via ftp (where I'm getting my metrics from and consisten wth those reported by iftop)...
nvram set usb_ftpsuper=1
nvram set usb_ftpsuper_x=1
nvram set proftpd_writeen=1
nvram set w1l_distance=200 (was 3000!)
nvram commit && reboot

squeezed another 1MBps - but still not USB3 speed.

EDIT:
nvram set wl1_txstreams=2 (was=0) and rxstreams , has now bumped up speed to 25MBps

SOLVED!!!! wl1_streams was not set correctly and not visible in your / ausus or DDW RT f/w.
All the wifi clients in the home are now transfering data at around 25MBps on a 802.11n LAN. Soon to be 802.11ac ! But 20MBps is around 200mbps which on 802.11n is fine as a mean throughput
THIS IS MORE LIKE IT - now i see how Asus manage to "downgrade" the AC56U when in reality its performance is on par with the 68U (or can be with some nvram tweaks)

nvram set wl0_rxstreams=2
nvram set wl0_txstreams=2
nvram set wl1_rxstreams=2
nvram set wl1_txstreams=2
 
Last edited:

Latest threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!

Members online

Top