What's new
  • 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!

RT-AC87U: get live traffic stats?

emseli

New Around Here
Hi there!

I wonder if it is possible, to get the current rx/tx speeds of the router (like traffic monitoring page) via curl/wget from another computer in the network.
I have a small arduino bandwith meter project in mind and need to poll these stats.

Any hints?
 
No. The webui does not offer any RESTful API, and you'll have a hard time scraping the webui (assuming you'd manage to make curl work with the session authentication scheme).

Why not use SNMP?
 
Didn't know the router had that feature tbh :)
What oids does it use for up/download?

No idea, I don't use SNMP myself. The router uses whatever is standard for Linux systems.
 
No idea, I don't use SNMP myself.
So, SNMP gives reliable data. But it reports the same packets IN/OUTBOUND. It shows the same speed for up and download :(
Deactivating NAT Accelaration doesn't help much, it just makes the connection a lot slower.

What's interesting to me: the gauges on the Adaptive QoS page seem to be accurate enough. Where do they get their speeds? Is there any way (SSH, Telnet, etc.) to access them?
 
So, SNMP gives reliable data. But it reports the same packets IN/OUTBOUND. It shows the same speed for up and download :(
Deactivating NAT Accelaration doesn't help much, it just makes the connection a lot slower.

Not surprised. The Ethernet driver has been broken for well over a year now, reporting the wrong inbound/outbound traffic. This is part of the same issue that prevents Traditional QoS from working.

Where do they get their speeds? Is there any way (SSH, Telnet, etc.) to access them?

Trend Micro DPI engine.
 
Not surprised. The Ethernet driver has been broken for well over a year now, reporting the wrong inbound/outbound traffic. This is part of the same issue that prevents Traditional QoS from working.



Trend Micro DPI engine.
so what other issues exist cause the driver is broken and what models are affected?
 
Not surprised. The Ethernet driver has been broken for well over a year now...

Trend Micro DPI engine.

Well, that sucks :(
I tried to look into the code of the getTraffic.asp. It only says

router_traffic = <% bwdpi_status("traffic_wan", "", "realtime", ""); %>;

Couldn't find the function bwdpi_status in the codebase though - where are those functions defined?

So I sshd to the router, punched in "bwdpi stat -m traffic_wan -u realtime" and now I'm absolutely unsure, what I'm looking at:

[stat] total_up/total_down=1296/648
[stat] total_up/total_down=7124/6080
[stat] total_up/total_down=104251288/990822837
[stat] total_up/total_down=104270850/990848032
[stat] total_up/total_down=104434100/991073759
[stat] total_up/total_down=104451639/991102408
[stat] total_up/total_down=104453631/991120172
[stat] total_up/total_down=104459992/991131803
[stat] total_up/total_down=104482424/991196632

What are these numbers supposed to mean? I looked around the web, but the dpi tool is not really well documented.


EDIT: got it to work :)
Use this bash script to measure your bandwith. It's not extremely accurate or even "real time" but it should suffice for home use.

https://gist.github.com/a3rosol/ba74e00caf6cc842de3a8f558db43337

I will add more stuff to this script, but for now, it's enough
 
Last edited:
so what other issues exist cause the driver is broken and what models are affected?

I don't know, I didn't check all models. I only know the RT-AC88U is affected, which means probably at least the AC3100 and AC5300 as well.
 
where are those functions defined?

Those are parsed by the web server before sending the page to the browser. Every <% %> tag is preprocessed internally by the web server.
 
I don't know, I didn't check all models. I only know the RT-AC88U is affected, which means probably at least the AC3100 and AC5300 as well.
ahh lovely, I wish ASUS would do something about it*sigh*.
 
I have been using an RT-AC87U for several months - I was getting plausible receive/transmit stats on both the ASUS firmware and Merlin firmware. I recently switched ISP to a fiber-based provider. There is no modem, it just presents a WAN connection to the router. Due to issues getting it working (turned out to be a bad fiber box) I wound up reverting to factory default with ASUS firmware. After all was working fine, I re-installed Merlin firmware but now I get essentially zero receive traffic showing. I have switched back to ASUS and inbound traffic is reported but reinstalling Merlin (380.66, 380.67, 380.68 pre-release) I get the same virtually nil reporting of receive traffic.

I'm hesitant to do a factory reset because the ISP requires the WAN to be on DHCP and it tracks address requests - after giving out one IP address the account will lock if a second request is made. I don't want to do anything that will generate another IP address...

Any suggestions would be greatly appreciated.

Thanks in advance.
 

Similar 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!
Back
Top