Netpy installation instructions

Required software

To run Netpy, you need to have the following packages installed onto your computer:

We tested Netpy on various flavours of Linux, with Python 2.4, flow-tools 0.66, gd 2.0.33, gdmodule 0.56, and wxPython 2.4.2.4 (the latest stable version at the time). It will probably work with other versions of these packages, possibly on other operating systems, but it might require small fixes.

Building Netpy

The only thing you need to compile for Netpy to run is the C++ backend implementing the database and the analysis. The binary file packaged with netpy (netpy2/src/netpy/backend/netpybackend.so) might work with your system. If not, you need to recompile it by doing the following.

  • Edit the Makefile from the netpy2/src/netpy/backend directory to ensure that the include path points to the directory of your system holding the flow-tools include files and to the directory with you Python.h file.
  • In the Makefile set the C++ compiler and linker to the one present on your system.
  • Run make

Running Netpy

Make a copy of netpy2/etc/example_netpy.conf to use as your netpy configuration file. Edit the netpy configuration file to reflect the path to your netpy installation, the path to the wxPython and gdmodule python modules (if installed to nonstandard locations). If gdmodule is linked dynamically against gd and it is in a non-standard location you might have to set your LD_LIBRARY_PATH environment variable before running the Netpy GUI. Create a directory for keeping the database (a relatively flat hierarchy of files with flow records in netpy's custom format) and point the DB entry in the netpy configuration file to it. Edit the LINK_INFO and TRAFFIC_CLASSIFICATION sections to reflect how you want the database to group NetFlow records by links. If you do not want to separate your traffic by links, just create a single entry in the LINK_INFO section and map all the traffic to it in the TRAFFIC_CLASSIFICATION section using a line similar to the last one in the example configuration file. If you do not want to use user defined categories delete or comment out the USER_DEFINED_CATEGORIES_FILE entry. You can add the user defined categories file later and you can modify it any time (it is read in every time you preform an analysis using user defined categories).

To run Nepty do the following.

  • For the console, run python netpy2/src/netpy/console/netpyConsole.py your_nepty_configuration_file
  • For the GUI, run python netpy2/src/netpy/ui/netpyGUI.py your_nepty_configuration_file