##########################################
   Network Traffic Analyzer README file
##########################################


Requirements
~~~~~~~~~~~~

The basic for every computer is operating system. This software runs well
on Linux, but it maybe can be ran on other platforms, I don't know. Please
let me know if you are more experienced with it. This software is a package
of few simple Perl scripts which generate static HTML files and some
pictures using the GD library.

List of requirements:
---------------------
  Perl >= 5.6.0, older versions can work too, I think
    http://www.perl.org/
  GD >= 1.8 with PNG support
    http://www.boutell.com/gd/
  GD.pm, Perl interface to GD Graphics Library
    http://stein.cshl.org/WWW/software/GD/
  Linux operating system with working <tt>ifconfig</tt>, procfs
    and running cron daemon
    http://www.linux.org/

Note 1: On my old computer (Pentium 166 MHz MMX, 192M RAM, with a really lot
of processes running) I've tried to create full stats of last 24 hours, 7
days, 4 weeks and 6 months. The script was running for about 9 seconds.

Note 2: The script stores its data in a few files. You should have about
20kB free disk space per graph per network device.


License
~~~~~~~

This software is distributed under the terms of GPL.
See COPYING filefor more details.


Download
~~~~~~~~

All about downloading is on the NTA homepage.
http://nta.kyberdigi.cz/


Installation
~~~~~~~~~~~~

First, unpack the archive.
$ tar xzf nta-1.0.tar.gz

Now you should see a directory nta-1.0, so step into it.
$ cd nta-1.0

Well, that's it! ;-) You don't need to copy this files anywhere,
the location of these files doesn't matter. But I strongly recommend
you not to copy any of here located files away.

You don't need to be the superuser. For installing and running this
software, it is absolutelly O.K. to be a non-privileged user.


Configuration
~~~~~~~~~~~~~

Before the first run, you should edit the config.pl file, which
is the only configuration file for this simple software. Use your favorite
text editor for this action.

First of all you have to define network devices, which should the software
look at. You can usually list your network devices via the ifconfig
command. You can name each of devices listed in output of this command.
Here is an example:

  %netdevices=(
    'eth0' => 'Main Internet connection',
    'eth1' => 'Local subnet',
    'lo'   => 'Loopback device'
  );

Usually your home computer has only one network device, so it is O.K. to have
such simple configuration of devices:

  %netdevices=(
    'eth0' => 'Main Internet connection'
  );

The rest of the config.pl file is a big %config variable.
You don't need to see all of it, but please take a good care about line
output_dir, where you must specify an existing directory with write
access. You can edit the other lines too, they are well commented, so it
should be not a problem for anybody to change configuration of whatever he
wants.


Running
~~~~~~~

The main script nta.pl needs to be executed every 5 minutes to create
correct stats. Use cron daemon to do it, for example via the crontab -e
command. I strongly recommend you not to do it as root, use non-privileged
account for this action. Put this line to the crontab file:

*/5 * * * * (cd /full/path/to/nta-1.0/; ./nta.pl)

I also recommend you to check if everything works before crontab editing.
Just step into the nta directory and run the nta script:

$ cd /path/to/nta-1.0/
$ ./nta.pl

If you can't see any output, everything works fine. Other way you should get
an error message. Check the output it the output directory specified in
config.pl file.


Bugs
~~~~

There are no known bugs at this moment. If you know about any, just
send me an e-mail message to mccohy@kyberdigi.cz.


