Results 1 to 4 of 4

Thread: Programming an internet usage monitor.

  1. #1
    Just burned his ISO
    Join Date
    Jul 2009
    Posts
    5

    Default Programming an internet usage monitor.

    I want to write something which monitors internet usage and emails it to me. I know that there are plenty of these programs available for download but I am more interested in how it all works than actually using it. If anyone can give me some direction it would be much appreciated. Google yields a lot of commercial results, which are not very fruitful to this particular endeavor. Many thanks.

  2. #2
    Senior Member streaker69's Avatar
    Join Date
    Jan 2010
    Location
    Virginville, BlueBall, Bird In Hand, Intercourse, Paradise, PA
    Posts
    3,535

    Default

    Quote Originally Posted by slykehn View Post
    I want to write something which monitors internet usage and emails it to me. I know that there are plenty of these programs available for download but I am more interested in how it all works than actually using it. If anyone can give me some direction it would be much appreciated. Google yields a lot of commercial results, which are not very fruitful to this particular endeavor. Many thanks.
    Most of the graphing programs out there that are opensource are using RRDTool written by Tobias Ottiker and then they write a display interface on top of that. I'm not sure why you would want to go and re-invent the wheel though when there's lots of good solutions already out there that you can view their source and see how they work.

    Cacti is good, so is Ntop. You'll need hardware that supports SNMP to be able to graph traffic flows. Getting managed hardware is normally out of the price range for your normal home network though.
    A third party security audit is the IT equivalent of a colonoscopy. It's long, intrusive, very uncomfortable, and when it's done, you'll have seen things you really didn't want to see, and you'll never forget that you've had one.

  3. #3
    Very good friend of the forum Gitsnik's Avatar
    Join Date
    Jan 2010
    Location
    The Crystal Wind
    Posts
    851

    Default

    First note that I fully support what streaker has said, however I am not closed to the idea of re-inventing the wheel to learn or re-iterate an issue. It's a good method of learning.

    So, two tips:

    1. iptables matches packet counts to rules if you do it right. You can poll these out if you like (I've done this previously).
    2. A more accurate option is to crack open a (perl) script that sniff's the interface and logs the size of each packet, source/dest and ports. I've also done this but it proved to be overkill, the packet-logger above was just as useful.
    Still not underestimating the power...

    There is no such thing as bad information - There is truth in the data, so you sift it all, even the crap stuff.

  4. #4
    Just burned his ISO
    Join Date
    Jul 2009
    Posts
    5

    Default

    Ok so my first goal is simply keeping track of websites visited (much like the big brother software some parents use to monitor children). I have found some info on .dat files storing this information even after history is deleted. Has anyone ever tried mining these files to accomplish this? Obviously it's not nearly as dynamic or accurate as packet monitoring, but it has piqued my interest. Thank you for the responses by the way; I have looked into both presented solutions and found intriguing information.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •