Showing posts with label flow-viewer. Show all posts
Showing posts with label flow-viewer. Show all posts

Thursday, May 7, 2015

How to install Flow-tools and Flow-viewer on Centos 6.5

This document is specifically made for installing the Flow-tools on Centos 6.5 and Below version of Flow-tools and Flow-viewers are used in it.

    Flow Tools:   flow-tools-0.68.5.1
    Flow Viewer:  FlowViewer_4.6

Flow-tools Installation:

Download the flowtools and install it...
        wget https://flow-tools.googlecode.com/files/flow-tools-0.68.5.1.tar.bz2
        tar -xvjf flow-tools-0.68.5.1.tar.bz2
        cd flow-tools-0.68.5.1
        yum install make tcp_wrappers zlib gcc
        ./configure
        gmake
        gmake install


Install FlowViewer Dependencies:
           yum install gd libgd gd-devel rrdtool
    Download  and install GD for cpan:      
           wget http://search.cpan.org/CPAN/authors/id/L/LD/LDS/GD-2.56.tar.gz
           tar -zxvf GD-2.56.tar.gz
           cd GD-2.56
           perl ./Build.PL
           ./Build
           sudo ./Build install       
           yum install perl-ExtUtils-MakeMaker*
    Download and install ExtUtils-makeMaker
           wget http://search.cpan.org/CPAN/authors/id/M/MS/MSTROUT/ExtUtils-MakeMaker-6.58_01.tar.gz
           tar -zxvf ExtUtils-MakeMaker-6.58_01.tar.gz
           cd ExtUtils-MakeMaker-6.58_01
           perl Makefile.PL
           make
           sudo make install
FlowViewer installation and configuration:
           wget http://downloads.sourceforge.net/project/flowviewer/FlowViewer_4.6.tar
          tar -xvf FlowViewer_4.6.tar
          yum install httpd
          mv FlowViewer_4.6 /var/www/cgi-bin/flowviewer

FlowViewer Configuration:

Edit the FlowViewer_Configuration.pm file and update the path.. make sure the Paths are Valid if the Floders are not exist.. Please create it manually.
Copy the config file to the correct directory.
          cp /var/www/cgi-bin/flowviewer/tools/flow-capture-table.conf /etc/flow-capture-table.conf

Edit the flow-capture-table.conf file and update the router and port number details.
Copy the flowcapture init script to the init.d directory.
           cp /var/www/cgi-bin/flowviewer/tools/flowcapture_restart /etc/init.d/flowcapture

Start the flowcapture..
            /etc/init.d/flowcapture start

Point your browser to http://<YOUR -SERVER_IP>/cgi-bin/flowviewer/FV.cgi

P.S: flowgrapher Setup is not updated in the installtion. I will add it in future..

P.S: Use http://ipsubnetcalculator.net/  for calculating IP subnet mask Online

Monday, June 9, 2014

How to install Flow-tools and Flow-viewer on Centos 5.4

Installing Flow-tools and Flow-viewer on Centos 5.4

Make sure you have the gnu make package installed on your system.
you can check this by using the below command, if not installed install the same using yum install make

#  rpm -qa | grep make

Install dependencies, Download the dependecy package zlib and install it

# wget http://zlib.net/zlib-1.2.8.tar.gz
# tar -xvf zlib-1.2.8.tar.gz
# cd zlib-1.2.8
# ./configure
# make
# make install
# yum install tcp_wrappers

 


Installing flow-tools: Download Latest flow-tools from from https://code.google.com/p/flow-tools/

#  wget https://code.google.com/p/flow-tools/
# tar  -xjvf flow-tools-0.68.5.1.tar.bz2.
# cd flow-tools-0.68.5.1
# ./configure
# make
# make install


Install flow-viewer: Download the latest flow-viewer from http://sourceforge.net/projects/flowviewer/ and Move the flow-viewer files to cgi-bin directory of your server and install the dependencies

# untar FlowViewer_4.4.tar
# mv FlowViewer_4.4 /var/www/cgi-bin/flowviewer
# yum install gd-devel
# cpan GD
# /usr/bin/make install  -- OK
# cpan GD::Graph
# yum install rrdtool
# cd /var/www/cgi-bin/flowviewer/tools

Move flow-capture-table.conf to /etc/flow-capture-table.conf
Edit the file with the your router ip address and port number.

# mv /var/www/cgi-bin/flowviewer/tools/flowcapture_restart /etc/init.d/flowcapture

edit the /etc/init.d/flowcapture file and make sure the below paths are mentioned correctly and have the valid path.

# USER=root
# RRDTOOL_PATH=/usr/bin
# FLOW_CAPTURE_TABLE=/var/flow-tools/flow-capture-table.conf
# FLOW_CAPTURE_BIN=/usr/bin/flow-capture
# FLOW_CAPTURE_PID_DIR=/var/run/flow-capture.pid

# cd /var/www/cgi-bin/flowviewer/tools/
# mv flowtracker_restart /etc/init.d/flowtracker

Make sure the below paths are correct in the flowtracker file

FlowViewer=/var/www/cgi-bin/flowviewer
user=root
RRDTOOL_PATH=/usr/bin

Start the Flow-viewer and flow-tracker

# /etc/init.d/flow-capture start
# /etc/init.d/flow-tracker start

Point your web brouser to the below url (replace the ip address with your server ip).

https://192.168.1.1/cgi-bin/flowviewer/FlowViewer.cgi


You are done installing a great netflow tool. Enjoy!!!


P.S: Use http://ipsubnetcalculator.net/  for calculating IP subnet mask Online