Simple Bandwidth Monitoring - Part 2
I recently did a video on some really great tools for monitoring your machine's bandwidth usage on Linux / Unix. If you haven't checked it out, I highly recommend it, as these are some top notch tools for determining how much bandwidth you are using, what applications are using the bandwidth, and tracking down potential issues. I'll linke that video near the end of the article.
Today, I wanted to cover a few more tools that provide some incredible information about your bandwidth usage, network interfaces, and more. Some of these I stumbled across as I was looking for tools that can monitor an entire network's usage (video coming later), and a few were mentioned in the comments of my previous video as solid tools. I have to agree, as these are some really great tools.
The Tools
- Nethogs - https://github.com/raboof/nethogs
- Speedometer - https://excess.org/speedometer/
- ipTraf - http://iptraf.seul.org/
Installation
Nethogs
Nethogs is an excellent little CLI tool that will show you which applications and pages are using your bandwidth, and more specifically, which ones are using the most bandwidth (or hogging it).
You can install it with
Ubuntu / Debian based distros (you may need sudo)
apt-get install build-essential libncurses5-dev libpcap-dev
sudo apt install nethogs
Yum based distros
yum install gcc-c++ libpcap-devel.x86_64 libpcap.x86_64 "ncurses*"
yum install nethogs
NOTE: You may or may not need the development tools, but if you really want to run and use open source, self hosted software, it's never a bad idea to have those installed anyway.
Running Nethogs
This is probably one of the easiest tools to run. You'll want to run it with sudo
so that it can access the network interface and application information.
sudo nethogs

The screen will fill and give you a list of which interfaces are using bandwidth, as well as which applications.
Use the 'Q' keyboard press to quit the application and return to the normal prompt.
Installation
Speedometer
Next up, we have Speedometer. This tool provides a nice graphical looking view right in the terminal for your current bandwidth usage on any interface. It shows a wave form of usage for both upload and download, and really isn't too hard to use, but there are some flags and arguments you'll need on the command line.
First let's install with
sudo apt-get install speedometer
I'll give you a starter command here, but make sure to check out the man pages to get the most out of this tool.
speedometer -l -r <interface name> -t <interface name> -m $(( 1024 * 1024 * 3 / 2 ))
Check out the link at the top of the page to see what else Speedometer can do.

Installation
IPTraf
ipTraf is likely one of the most powerful and capable tools we have looked at thus far. The interface colors (IMO) lack something to be desired, but this can be turned off for a more legible look. You can see how to do this in my video linked at the top of the post.
To install ipTraf, we actually want to install ipTraf-ng, and do that with the command:
sudo apt install iptraf-ng
We can then run it with
sudo iptraf-ng
You'll be presented with a very bright list of options on the terminal screen. You can choose options by using the letter key associated to the menu item.
You can dig down into menus, make changes to settings, and use ipTraf to run all kinds of great diagnostics on your interfaces and network capabilities.
