It is important to know traffic usage of your client if you’re a Linux network administrator. You can monitor your client in text mode, graphic mode or html exported like mrtg, cacti or bandwidthd and one of my favorite bandwidth monitor is bandwidthd.
BandwidthD tracks usage of TCP/IP network subnets and builds html files with graphs to display utilization. Charts are built by individual IPs, and by default display utilization over 2 day, 8 day, 40 day, and 400 day periods. Furthermore, each ip address’s utilization can be logged out at intervals of 3.3 minutes, 10 minutes, 1 hour or 12 hours in cdf format, or to a backend database server. HTTP, TCP, UDP, ICMP, VPN, and P2P traffic are color coded.
Download Bandwidthd form http://sourceforge.net/projects/bandwidthd/files/
[root@arslan]# tar xvfz bandwidthd-2.0.1.tgz
[root@arslan]# cd bandwidthd
Configure and install the Bandwidthd source:
[root@arslan]# ./configure && make install
Please make sure you have:
libpcap from http://www.tcpdump.org/
libpng from http://www.libpng.org/
libgd from http://www.boutell.com/gd/
Now Edit /usr/local/bandwidthd/etc/bandwidthd.conf
to suit your network environment.
My Example is :
Now Start Bandwidthd
You can’t see your graphic report until you set /usr/local/bandwidthd/htdocs/ folder to set as apache virtual directory. Add below line to your apache config file.
Alias /bandwidthd “/usr/local/bandwidthd/htdocs”
Allow from All
now go to browser and write http://your-server-ip/bandwidthd