Asus RT-AC58U OpenWrt with high delay of LAN

When I use firmware from ASUS, the delay of LAN is very slow.
For example about 1 or 2ms with packet size for 50000 (ping 192.168.1.1 -l 50000)
When I use OpenWRT 19.07.2, the delay becomes higher and unstable.
For example between 4 to 10ms.

来自 192.168.1.1 的回复: 字节=50000 时间=7ms TTL=64
来自 192.168.1.1 的回复: 字节=50000 时间=10ms TTL=64
来自 192.168.1.1 的回复: 字节=50000 时间=4ms TTL=64
来自 192.168.1.1 的回复: 字节=50000 时间=8ms TTL=64
来自 192.168.1.1 的回复: 字节=50000 时间=10ms TTL=64
来自 192.168.1.1 的回复: 字节=50000 时间=10ms TTL=64
来自 192.168.1.1 的回复: 字节=50000 时间=10ms TTL=64
来自 192.168.1.1 的回复: 字节=50000 时间=5ms TTL=64

Can I change some configuration to fix it?

Is this host connected by cable to the lan or wifi?
What is the cpu utilization when you run the ping? top

This is my notebook. It connected to the ac58u with a cable of 1Gbps.
The cpu utilization of the ac58u is nearly 0%, because I only power on the router and ping it.
When I connected to other router(TPLINK 7500 v3、XiaoMi R3P) and ping -l 50000, I got about 4ms.
When I restored ac58u to the default firmware from ASUS(version 300438252134) and ping -l 50000, I got about 4ms too.

And when I install openwrt 19.07.2, I use the "Easy Installation" method of this link:
https://openwrt.org/toh/asus/rt-ac58u

One might argue that even the 4ms is not an ideal time, I got for example 1,5ms with mine

rendy@garida:[~]$ping -c 10 -s 50000 10.0.2.1
PING 10.0.2.1 (10.0.2.1) 50000(50028) bytes of data.
50008 bytes from 10.0.2.1: icmp_seq=1 ttl=64 time=1.56 ms
50008 bytes from 10.0.2.1: icmp_seq=2 ttl=64 time=1.42 ms
50008 bytes from 10.0.2.1: icmp_seq=3 ttl=64 time=1.40 ms
50008 bytes from 10.0.2.1: icmp_seq=4 ttl=64 time=1.40 ms
50008 bytes from 10.0.2.1: icmp_seq=5 ttl=64 time=1.77 ms
^C
--- 10.0.2.1 ping statistics ---
5 packets transmitted, 5 received, 0% packet loss, time 4006ms
rtt min/avg/max/mdev = 1.405/1.515/1.772/0.140 ms

I suppose you are using the same cable, right?

Yes, the same cable.
I tried 5GHz WIFI to ping 192.168.1.1 and also got unstable delay.
When I tried 5GHz WIFI to ping other routers or ac58u with AUSU offical firmware, the delay is stable.

Hello.

Not sure if you've fixed the problem but I recently upgraded to that firmware today and it also caused me a lot of delay over ethernet and no issues over wifi.

Using https://www.asus.com/support/FAQ/1000814// (Rescue mode) I downgraded the firmware to one prior and it has seemed to fix the issue.

FW_RT_AC58U_300438252134 -> FW_RT_AC58U_300438251939 (my current version).

Version 3.0.0.4.382.51939
2019/12/2326 MBytes

Hopefully it fixes it.

Sorry, I've flashed OP-BOOT before. So I can not enter "Rescue mode".
I tried to use OP-BOOT restore the system to FW_RT_AC58U_300438252134. And the delay of ethernet is OK.
I tried snapshot version r13136-ad27c133eb. And the delay of ethernet is better than OpenWrt 17.09.2. But it's higher than FW_RT_AC58U_300438252134.

Quite late, after 2 years, but I maybe found the solution.
I'm "playing" with an Asus RT-AC58U router now, and i'm was faced with this ping problem.
When the router's CPU is idle, the ping is around 2 ms. When I transfer data trough it, the ping becomes to normal, below 1 ms, so I trying to set the CPU's scaling governor from ondemand to performance and after this the ping goes to normal value when router is idle.

echo performance > /sys/devices/system/cpu/cpufreq/policy0/scaling_governor

Pinging with performance

PING openwrt.lan (192.168.1.1) 56(84) bytes of data.
64 bytes from openwrt.lan (192.168.1.1): icmp_seq=1 ttl=64 time=0.341 ms
64 bytes from openwrt.lan (192.168.1.1): icmp_seq=2 ttl=64 time=0.287 ms
64 bytes from openwrt.lan (192.168.1.1): icmp_seq=3 ttl=64 time=0.266 ms
64 bytes from openwrt.lan (192.168.1.1): icmp_seq=4 ttl=64 time=0.254 ms
64 bytes from openwrt.lan (192.168.1.1): icmp_seq=5 ttl=64 time=0.277 ms

Pinging with ondemand

PING openwrt.lan (192.168.1.1) 56(84) bytes of data.
64 bytes from openwrt.lan (192.168.1.1): icmp_seq=1 ttl=64 time=1.58 ms
64 bytes from openwrt.lan (192.168.1.1): icmp_seq=2 ttl=64 time=1.27 ms
64 bytes from openwrt.lan (192.168.1.1): icmp_seq=3 ttl=64 time=1.29 ms
64 bytes from openwrt.lan (192.168.1.1): icmp_seq=4 ttl=64 time=1.34 ms
64 bytes from openwrt.lan (192.168.1.1): icmp_seq=5 ttl=64 time=1.45 ms