What's new

[Beta 3] Vnstat on Merlin - UI, CLI and email - data use monitoring - now with data limit monitoring

  • 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!

Status
Not open for further replies.
@dev_null

Forgot to mention, 1 more thing I did was add ntpMerlin script and select chrony as the time server. I doubt this has anything to do with vnstat but it was around 3/4 I think when I added that

Edit: It was 3/6 that I added ntpMerlin
 
Last edited:
@dev_null
vnstat-export-db.txt
Code:
version;3
active;1
interface;eth0
nick;eth0
created;1614571993
updated;1615213801
totalrx;17592186380733
totaltx;19590
currx;182924857344
curtx;7335038976
totalrxk;169
totaltxk;155
btime;1615065263
d;0;1615179633;12801;808;243;125;1
d;1;1615093223;20461;1983;533;388;1
d;2;1615006854;160354;5325;800;463;1
d;3;1614920444;36142;1843;230;333;1
d;4;1614834035;20613;890;137;237;1
d;5;1614747639;19479;1437;828;930;1
d;6;1614661226;37752;1702;1019;358;1
d;7;1614574816;17592186072344;5570;624;490;1
d;8;1614571993;782;28;875;927;1
d;9;0;0;0;0;0;0
d;10;0;0;0;0;0;0
d;11;0;0;0;0;0;0
d;12;0;0;0;0;0;0
d;13;0;0;0;0;0;0
d;14;0;0;0;0;0;0
d;15;0;0;0;0;0;0
d;16;0;0;0;0;0;0
d;17;0;0;0;0;0;0
d;18;0;0;0;0;0;0
d;19;0;0;0;0;0;0
d;20;0;0;0;0;0;0
d;21;0;0;0;0;0;0
d;22;0;0;0;0;0;0
d;23;0;0;0;0;0;0
d;24;0;0;0;0;0;0
d;25;0;0;0;0;0;0
d;26;0;0;0;0;0;0
d;27;0;0;0;0;0;0
d;28;0;0;0;0;0;0
d;29;0;0;0;0;0;0
m;0;1614574816;17592186379950;19561;318;252;1
m;1;1614571993;782;28;875;927;1
m;2;0;0;0;0;0;0
m;3;0;0;0;0;0;0
m;4;0;0;0;0;0;0
m;5;0;0;0;0;0;0
m;6;0;0;0;0;0;0
m;7;0;0;0;0;0;0
m;8;0;0;0;0;0;0
m;9;0;0;0;0;0;0
m;10;0;0;0;0;0;0
m;11;0;0;0;0;0;0
t;0;1614574816;17592186072344;5570;624;490;1
t;1;1615006854;160354;5325;800;463;1
t;2;1614661226;37752;1702;1019;358;1
t;3;1614920444;36142;1843;230;333;1
t;4;1615093223;20461;1983;533;388;1
t;5;1614834035;20613;890;137;237;1
t;6;1614747639;19479;1437;828;930;1
t;7;1614571993;782;28;875;927;1
t;8;0;0;0;0;0;0
t;9;0;0;0;0;0;0
h;0;1615183176;1863391;72191
h;1;1615186779;1982458;42982
h;2;1615190382;1437954;37565
h;3;1615193985;1495367;60841
h;4;1615197588;1554492;363099
h;5;1615201191;1957976;121323
h;6;1615204794;1137085;49066
h;7;1615208397;584680;29334
h;8;1615211940;842836;34210
h;9;1615213801;252228;16906
h;10;1615132795;835619;283217
h;11;1615136398;857037;224615
h;12;1615139941;769138;264105
h;13;1615143543;690573;136226
h;14;1615147146;656915;28251
h;15;1615150749;539347;26595
h;16;1615154352;702181;29449
h;17;1615157955;738322;30812
h;18;1615161558;529037;30314
h;19;1615165161;1782337;69243
h;20;1615168764;694971;37523
h;21;1615172367;566828;28673
h;22;1615175970;608533;32237
h;23;1615179573;671085;35772


vnstat.txt


vnstat -h


NOTE: I have not reset. I'll wait in case you need something else
Yeah, I can see the occurrence in the daily, monthly and totals, but the hourly misses it because this version of vnstat doesn't present more than the previous 24 hours. If it happens again, can you snapshot (particularly the vnstat -h) when you notice it?

@dev_null

Forgot to mention, 1 more thing I did was add ntpMerlin script and select chrony as the time server. I doubt this has anything to do with vnstat but it was around 3/4 I think when I added that

Edit: It was 3/6 that I added ntpMerlin
Good recall. I just added/deleted ntpMerlin and swapped timeservers and couldn't reproduce it.

At this point I have no additional requirements for data, so go ahead and reset.

(If you were feeling adventurous - and the history is important to you -, you could export again, modify those 17592186072344 entries to something similar to the previous days, tweak the month number, save that file and import it. This is entirely untested, so YMMV. Specific steps on export/import/vnstat restart are on the portal.)
 
Yeah, I can see the occurrence in the daily, monthly and totals, but the hourly misses it because this version of vnstat doesn't present more than the previous 24 hours. If it happens again, can you snapshot (particularly the vnstat -h) when you notice it?


Good recall. I just added/deleted ntpMerlin and swapped timeservers and couldn't reproduce it.

At this point I have no additional requirements for data, so go ahead and reset.

(If you were feeling adventurous - and the history is important to you -, you could export again, modify those 17592186072344 entries to something similar to the previous days, tweak the month number, save that file and import it. This is entirely untested, so YMMV. Specific steps on export/import/vnstat restart are on the portal.)
Thanks, I'll probably mess something up if I tried to modify the data as you mention. I'm only losing 7 days or so. No big deal, I'll just reset.

BTW, after reset, do I need to reboot?
 
@dev_null

I ran a vnstat -r, checked GUI. Weird data was still there.
I then ran a vnstat --reset, checked GUI. Weird data was still there.
I then rebooted the router... Weird data was still there.

The reset didn't reset.
 
@dev_null

I ran a vnstat -r, checked GUI. Weird data was still there.
I then ran a vnstat --reset, checked GUI. Weird data was still there.
I then rebooted the router... Weird data was still there.

The reset didn't reset.
Hmmm, that is unexpected. Let's take this to PM and I'll update back here afterwards.
 
Device ASUS RT-AX88U firmware Asus Merlin 386.1_2. Re-installing the CLI did not give a result. Deleted opkg remove imagemagick --autoremove, opkg remove vnstat --autoremove, opkg remove vnstati --autoremove rebooted the device and installed it in a new way did not help. Another error when generating statistics via amtm in the screenshot.
convert: UnableToLoadModule '/tmp/mnt/app/entware/lib/ImageMagick-7.0.9/modules-Q8/coders/png.la': file not found @ error/module.c/OpenModule/1287.
convert: NoEncodeDelegateForThisImageFormat `LABEL' @ error/constitute.c/WriteImage/1222.
we're removing the need for imagemagick in the next version
 
we're removing the need for imagemagick in the next version
Indeed we are, but it's so aggravating when something like this shows up... grr.
 
Loving your efforts and outputs. Had been off the forum for about a week and it was so wonderful logging back in and finding the updates to this, amtm now including this and YazDHCP, and just brought a big smile to my face. Great community here.
 
I have just insalled VNSTAT from AMTM and all is good with the exception of this. I am currently running Merllin 386.2 Beta 1 on a AC86U router. I have tried the ctrl F5 and all other areas are being updated with current data, except for the below.

1615609097538.png
 
I have just insalled VNSTAT from AMTM and all is good with the exception of this. I am currently running Merllin 386.2 Beta 1 on a AC86U router. I have tried the ctrl F5 and all other areas are being updated with current data, except for the below.

View attachment 31908
I had to reinstall my vnstat 5 days ago and I only have 5 days in my top 10 (not today). You probably just need to wait until tomorrow
 
I had to reinstall my vnstat 5 days ago and I only have 5 days in my top 10 (not today). You probably just need to wait until tomorrow
Thanks for the reply and advice. I will check again tomorrow.
 
I have just insalled VNSTAT from AMTM and all is good with the exception of this. I am currently running Merllin 386.2 Beta 1 on a AC86U router. I have tried the ctrl F5 and all other areas are being updated with current data, except for the below.
I had to reinstall my vnstat 5 days ago and I only have 5 days in my top 10 (not today). You probably just need to wait until tomorrow
This is correct. A top-10 day isn't calculated until the following day (just after midnight, local time).
 
@dev_null thank you for this add-on, it's great.

I have noticed that the timing of the data seems to be off. The graph below shows data usage centered from 10pm to 5am. If I look at the built in Traffic Analyzer it correctly shows that data usage to be from 4pm to 11pm. Its almost as if the Vnstat graph should slide back by 6 hours. Have I missed a setting or have I discovered a bug?

vnstat_h.png
 
@dev_null thank you for this add-on, it's great.

I have noticed that the timing of the data seems to be off. The graph below shows data usage centered from 10pm to 5am. If I look at the built in Traffic Analyzer it correctly shows that data usage to be from 4pm to 11pm. Its almost as if the Vnstat graph should slide back by 6 hours. Have I missed a setting or have I discovered a bug?
Upon first use, I've observed this happen. It usually resolves itself.

There was one report of this not self-resolving. Here are the steps we took to resolve it:
  • Run nano /opt/etc/init.d/S33vnstat
  • Add as a separate line: export TZ=$(cat /etc/TZ) BELOW the "fi" line.
  • Save the file with CTLR+O (write) ENTER, then CTRL+X (exit).
  • Finally issue a /opt/etc/init.d/S33vnstat restart and press ENTER.

Let it run awhile and see if that fixes it. This does not seem like a widespread issue; hoping the above fixes it for you.
 
Is the top 10 a all time top 10 or a top 10 of the current month?
Well, I only started using this in December, so at least top for 3 months running (so: all time).

(And no, the command vnstat --cleartop --force does not appear to work in the entware 1.8 version of vnstat. Hopefully if entware updates to the 2.x version, some of these command line flags will be functional.)
 
when it's ready. assuming you've seen the commits, we have a LOT of good stuff coming
More than seeing it, I'm using it as a daily driver... All good (except allowance which keeps telling me that it doesn't have enough data to process)
 
More than seeing it, I'm using it as a daily driver... All good (except allowance which keeps telling me that it doesn't have enough data to process)
just to make sure that's not a bug, what do you get if you run:
Code:
vnstat -m --config /jffs/addons/dn-vnstat.d/vnstat.conf
 
Status
Not open for further replies.

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