Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

A big German ISP (Telekom) recently decided to volume limit their DSL internet connection to 75GB per month.

Now I would like to know how much I download / upload. I use Linux Mint 14 Nadia and I have a D-LINK DI-524 router.

How can I get the amount of data I upload / download per month?

share|improve this question
Someone already made a script for that. unix.stackexchange.com/questions/52153/… – Manuel Gutierrez Jun 26 '13 at 13:17

If you're looking for a user-friendly GUI app I'd recommend download monitor. You can view stats, assign quota etc.
A simple, nice CLI alternative is vnstat (howto).

share|improve this answer
This. vnstat will do all the work for you, after having it monitor try vnstat -m to see a monthly breakdown. I really think this is the tool for the job, personally. – dougBTV Jun 26 '13 at 12:31

The output from ifconfig contains packet and byte counters, normally listing the count since the system was booted up.

The information is also available in /proc/net/dev in a somewhat more machine-readable format.

share|improve this answer
I boot my system more than once in a month ;-P But thanks for the information. If there is no tool to do this, I'll write a snippet. – Martin Thoma Jun 26 '13 at 12:18
Add a periodic logging job and/or a shutdown task. I found one at ftp.linux.kiev.ua/pub/docs/mirrors/pm4u.opennet.ru/files/… but the script is atrocious. – tripleee Jun 26 '13 at 12:19

It's also worth noting for completeness' sake that some routers (a specific example being my Cisco small-business-geared model) provide information through their administration interfaces about how much data has been transferred. Mine can be configured to reset the counters at a specified interval, email reports and implement limits in addition to simply displaying the numbers in its web interface.

I have no idea if the DI-524 specifically has such capabilities, but it might be worth having a look through its administration interface just in case. Since the router is generally restarted much more rarely, it would probably provide relatively useful data, and it also won't be limited to one particular host, which may or may not be of interest.

share|improve this answer

Your Answer


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.