vnStat for monitoring network traffic through interfaces


We all live in a world surrounded by networks. The most important among them, and no doubt in that, is internet technology. When we relate networks to the computer systems, it is GNU/Linux dominating this particular field (again no doubt). Organizations working under computer networks usually run on GNU/Linux environment. So there is a great need for monitoring the network traffic. vnStat arrives in such a situation rendering a great help towards the network world. It is a console-based network traffic monitor. It keeps a log of hourly, daily and monthly network traffic for the selected interface(s). vnStat can be used even without root permission on most systems. It will be helpful for some of you for accounting the amount of data being transfered from our system to the outside world. I will brief some basic command-line options to start with. Install the utility from your distro’s default package manager.

The basic format for vnStat is
vnstat [options]

For creating a new database for a particular interface
Read More »

Creating a wireless Ad-hoc network in GNU/Linux for sharing files

Screenshot from 2013-05-15 12:03:12

Here I explain what I did in Ubuntu 12.04 LTS. And will probably be similar in most of the GNU/Linux distros. This method requires a network manager for managing the different networks. First of all you need to ensure that your wireless interface card supports Ad-hoc networking. Because there are some which doesn’t support wireless Ad-hoc networks. Know your network controller by running lspci | grep -i network. Given below is a list containing some of the network controllers that supports Ad-hoc and there may be more in the list.


Step 1: Right click on the network manager icon->Edit connections. Now you will get a window similar to one displayed above.
If not try the Network Connections from the Preferences section.
Step 2: Click on the tab Wireless->Add.
Step 3: Enter the SSID as the name that should be displayed as the network name.
Step 4: Click on the Mode drop-down list to select Ad-hoc. Leave the remaining fields as it is.
Step 5: Click on the Wireless Security tab for adding a password and select one of the Security types listed.
Step 6: Type a password->Save.
If you need a static ip address then follow the sub-steps before saving
Step 6.a) Click the tab IPv4 settings and select the method as Manual.
Step 6.b) Click on add and then type a valid ip in Address section, as Netmask and as Gateway then Save.
Step 7: Click on the network icon again-> Connect to a hidden wireless network.
Step 8: Select the newly created network->Connect.

That’s all. Now this network will be shown in nearby computer’s network list.