Coder Social home page Coder Social logo

Comments (3)

vergoh avatar vergoh commented on July 4, 2024

Which vnStat version are you using?

The estimate is based on the average traffic rate so far for the selected time period. It doesn't have any understanding of any usage patterns as it's only doing linear estimation based on the current average. As a result, if you for example don't use the connection much during the night and then check the estimate the first things during the morning then that estimate isn't likely to be too accurate but it will improve as the day progresses.

As for the "inaccuracy" you are trying to understand, I suspect the problem is related to how you expect vnStat to be monitoring traffic. The thing is, vnStat isn't aware if the traffic it sees is something you'd count as "external" or "local". It only sees the amount of traffic seen by the network interface and if that interface can communicate with both "external" and "local" systems then both are being reported and there's no way to differentiate between those two. vnStat is still accurate in that case as that's all the traffic the interface being monitored sees.

from vnstat.

thelastindian avatar thelastindian commented on July 4, 2024
$ vnstat --version
vnStat 2.6 by Teemu Toivola <tst at iki dot fi>

I edited it in the original question too. I understand now why the traffic stats are the way they are. I still wish there was a way to distinguish between local and external traffic though.

Idk what I am talking about, but is there a way to make certain pathways not register on vnstat? I mean, I realize you said there is no way to differential between them, but if vnstat say measures different data flows and for scrcpy application say the data stream always going through a pre determined path, maybe one would be able to make vnstat ignore it?

Again, I am glad that vnstat is accurate and I really don't know what I am talking abt, but as an analogy, let's say there are 5 bridges and only 2 of these bridges are local bridges, then maybe if they bridges aren't changing (i.e., the data stream from that path is predictable) one can try to ignore it?

Again, I got my answer, thank you for your help and for your package!

If you need any other info or want to reply to my comments you can do that, I will be closing the issue after 24 hours.

from vnstat.

vergoh avatar vergoh commented on July 4, 2024

You can see the data that vnStat uses as source with cat /proc/net/dev. It's only interface metrics that are visible from there. There's no information what the traffic is about, which program has generated it or where the traffic going or coming. On the other hand, that's also the reason why the system resource usage of vnStat doesn't change at all no matter how much traffic you have as the kernel is doing all the work anyway.

The only option you have to separate the traffic for vnStat is to have more interfaces that are in some way use case specific. However, the catch is that those interfaces don't all need to be physical interfaces. For example, tunnel interfaces can be monitored so having some kind of VPN setup could be one option.

from vnstat.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.