I was wondering if there are any good applications to monitor how much data I use on my laptop in a month. My net connection has a restriction of how much data I can use after which the speed goes down considerably. I saw ntop, but I just wanted to ask if there are any other good options or suggestions regarding this. Regards.

share|improve this question
1  
Have you checked vnstat – Achu Feb 12 '12 at 17:30
    
You can use Data Monitor App for Linux – BigSack Aug 9 '12 at 9:36
up vote 15 down vote accepted

I was in a similar situation, but with slow speeds after a certain amount of data usage is reached (now I have a 16 GB 12 Mbit plan ☺) and I used vnstat (package vnstat). It's a command-line app that displays the bandwidth usage for today and previous days. as soon as it is installed, it will start monitoring the usage.

Usage: run vnstat to view the statistics, vnstat -d for viewing daily usage. Add -i wlan0 to the previous command if you are using a wireless network. See the manual page for it by running man vnstat for more information.

share|improve this answer
    
I used the same in the past, you can get a gui for it now apparently - never used that though - sqweek.com/sqweek/index.php?p=1 – 23 93 26 35 19 57 3 89 Oct 5 '13 at 14:03
    
Thank you .How can I configure that ? – Ten-Coin Oct 5 '13 at 14:23
    
@rajagenupula well, there is nothing to configure! as soon as it is installed, it will start monitoring the usage. Run vnstat to view the statistics, vnstat -d -i <interface> for viewing daily usage. See the manual page by running man vnstat for more information. – Ramchandra Apte Oct 5 '13 at 15:07

You can check NTM - Network Traffic Monitor

share|improve this answer
    
This is very easy to setup – Ten-Coin Oct 5 '13 at 14:29

There is Datafox, an addon for Firefox.

This should monitor at least your bandwidth usage on the web, I don't know if it can monitor usage with other applications however.

share|improve this answer
2  
Datafox has rather limited scope. From the add-on page: "Check your BSNL DataOne and MTNL Triband bandwidth utilization in Firefox at the click of a button." It doesn't seem to work for other ISPs. As you point out, monitoring bandwidth usage by other apps is also required. – user25656 Feb 13 '12 at 14:56

check the software at these site.You can track your data usage by using these applications. software recommendation

software recommendation

share|improve this answer
    
I have used NTM that was pretty easy to setup and nice. – Ten-Coin Oct 5 '13 at 14:20
    
ok enjoy and get away from extra bill – krishna kaanthh Oct 5 '13 at 14:23

I needed protocol granularity to see what was using data on my network, so I opted for ntop. It has a web interface, and worked out the box for me.

share|improve this answer

vnStat - Light Weight Console-based Network Monitor

vnStat is a console-based network traffic monitor for Linux and BSD that keeps a log of network traffic for the selected interface(s). It uses the network interface statistics provided by the kernel as information source. This means that vnStat won't actually be sniffing any traffic and also ensures light use of system resources.

In this tutorial we'll review:

  • Features
  • Installation
  • Configuration
  • Start Systemd Service
  • Usage (from command line)
  • Conky example

Features

  • quick and simple to install and get running
  • gathered statistics persists through system reboots
  • can monitor multiple interfaces at the same time
  • several output options
  • summary, hourly, daily, monthly, weekly, top 10 days
  • optional png image output (using libgd)
  • months can be configured to follow billing period
  • light, minimal resource usage
  • same low cpu usage regardless of traffic
  • can be used without root permissions
  • online color configuration editor

Installation

nvStat is in the official repositories so no need to link to a new ppa. To install create a Terminal instance using Ctrl+Alt+T and type at the prompt:

sudo apt-get install vnstat

After installation, keep your Terminal open for the following sections. There is no need to reboot.

Configuration

Pick a preferred network interface and edit the Interface variable in the /etc/vnstat.conf accordingly. To the list all interfaces available to vnstat, use:

vnstat --iflist.

To start monitoring a particular interface you must initialize a database first. Each interface needs its own database. The command to initialize one for the eth0 interface is:

sudo vnstat -u -i eth0 

Start Systemd Service

After introducing the interface(s) and checking the config file. You can start the monitoring process via systemd:

sudo systemctl start vnstat.service

To make this service permanent use:

sudo systemctl enable vnstat.service

From now on vnstat will be gathering network usage in the background using such a small percentage of CPU it doesn't show up on conky's (system monitor's) top 9 list of processes (on my machine).

Usage (from Command Line)

Query the network traffic:

vnstat -q

Viewing live network traffic usage:

vnstat -l

To find more options, use:

vnstat --help

Monthly Totals

To see monthly totals, use:

rick@dell:~$ vnstat -m

 eth0  /  monthly

       month        rx      |     tx      |    total    |   avg. rate
    ------------------------+-------------+-------------+---------------
      Nov '16     76.31 MiB |    2.03 MiB |   78.35 MiB |   10.45 kbit/s
    ------------------------+-------------+-------------+---------------
    estimated      3.13 GiB |      84 MiB |    3.21 GiB |

Conky example

Conky is a popular light-weight System Monitor used across many Linux distributions. You can vnStat bandwidth totals to your conky display like this:

enter image description here

Note when picture was taken Yesterday was Sunday which explains why the Weekly total is less.

The conky code to achieve this is:

${color orange}${voffset 2}${hr 1}
${color1}Network using vnStat "-i", "-w" and "-m"
${color}${goto 5}Today ${goto 100}Yesterday ${goto 225}Week ${goto 325}Month ${color green}
${execi 300 vnstat -i eth0 | grep "today" | awk '{print $8" "substr ($9, 1, 1)}'} ${goto 110}${execi 300 vnstat -i eth0 | grep "yesterday" | awk '{print $8" "substr ($9, 1, 1)}'} ${goto 220}${execi 300 vnstat -i eth0 -w | grep "current week" | awk '{print $9" "substr ($10, 1, 1)}'} ${goto 315}${execi 300 vnstat -i eth0 -m | grep "`date +"%b '%y"`" | awk '{print $9" "substr ($10, 1, 1)}'}
${color orange}${voffset 2}${hr 1}

To save space on my narrow window I used "G" instead of "GiB", "M" instead of "MiB", etc. If you have more screen realestate change substr ($10, 1, 1) to $10 and the same for $9.

You may have to change eth0 to wlan0 or eth1, etc. depending on your network name reported by ifconfig.

share|improve this answer

Sysstat is a professional command-line monitoring utility. Install it using following command:

apt-get install sysstat

Use sa1 to store system status for N seconds (It stores system statues in some binary files located at /var/log/sa):

sa1 1 N

At any time use sadf to view network usage in some standard formats:

sadf -d /var/log/sa/sa18 -s HH:MM:SS -e HH:MM:SS -- -n DEV

-s and -e specifies start time and end time. sa18 means day 18 of current month.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.