vortex-5 / ddwrt-bwmon

An Individual Bandwidth Monitor For DD-WRT
171 stars 37 forks source link

bandwidth is reported much smaller #73

Closed sgrgh closed 4 years ago

sgrgh commented 4 years ago

First, this is a fantastic piece of software with a well thought web interface running out of a router!

I have a dlink dir-880L running dd-wrt and bwmon, both installed at the same time today. The dlink is the primary router, and it serves my Netgear Orbi acting as an access point. Once I got the mac-names typed up, I could recognize every single device on bwmon, which is great.

I noticed towards mid-day after my install that dd-wrt traffic monitor showed several GB of total download (today), whereas bwmon total was about 700MB. I started to read your issue pages and found that recent thread on "wrong bandwidth", where you had provided this patch bwmon-BYTES.tar.gz. However, that did not make difference for me.

I think the calculations are off by a factor of 50 for me, atleast on the total. I just did a test download from here https://www.thinkbroadband.com/download of a 20 MB file on a device, and bwmon showed a 0.4MB increase for that device total.

My firmware is DD-WRT v3.0-r42617 std (03/05/20) Linux DD-WRT 4.4.215 #1052 SMP Wed Mar 4 12:16:22 +04 2020 armv7l DD-WRT

In the last couple days I've tried to monitor downloads on other devices and the calculations on both the live bandwidth and total data are off, and they seem to vary. I cannot figure how to calibrate it and fix the calculations in the code.

vortex-5 commented 4 years ago

Many users have reported that "shortcut forwarding engine" greatly affects the accuracy of the bwmon tool.

I have confimed on average the accuracy differs by about 30% (not exactly 50x like your example) but it's variable.

I'd try turning this off first and then retesting for a bit to see if this resolves your issue.

sgrgh commented 4 years ago

That's it, I disabled the SFE setting under Setup->BasicSetup under optional settings. Now, the totals are spot-on and I guess the live rates look pretty close to a youtube test. Thank you @vortex-5 ! The original install of dd-wrt has it enabled by default. I have multiple devices, and so far today I don't see any performance lag.

vortex-5 commented 4 years ago

In addition I will note if you're seeing high CPU usage version 4.1.0 tries to be nice to your CPU however it's a break from 3.0 version as everything is moved to cron jobs.

The downside is you don't get 10 second updates and updates only happen once a minute. This is a limitation of how frequently you can run cron operations.

If you like the behavior of your current version there's no rush to upgrade.

sgrgh commented 4 years ago

I am not sure if I can move up, because I did the dd-wrt webflash. It does not support later version (than DD-WRT v3.0-r40559 std (08/06/19)) for D-LINK DIR-880L.

BTW, it does not auto mount /opt. I found the uuid with blkid command and added it under Services->USB, but that doesn't work. I have to manually restart: mount /tmp/mnt/sda1/jffs /jffs cd /jffs/bwmon/ && sh install.sh /jffs/bwmon/startup.sh &

vortex-5 commented 4 years ago

ah I have mine automount to /jffs but if you have another automount location you can use that. The auto startup stopped working at some point on ddwrt versions starting with 4 now just put a routine in the routers startup commands but auto mounting is still required for that to work on every reboot.

you can also use CIFS (samba) file system as an alternative.

As for the UUID the service->USB should show you what the UUID you need to be using uuid