How to install iftop on Linux Servers

Installing iftop on a Linux system is straightforward and can be done using the package manager specific to your distribution. Here are the steps for some common Linux distributions:

On Debian-based systems (e.g., Ubuntu):

Update the package list:

sudo apt update
Install iftop:
sudo apt install iftop

On Red Hat-based systems (e.g., CentOS, Fedora, AlmaLinux, CloudLinux):

  1. For CentOS/RHEL/AlmaLinux/CloudLinux:
    • You may need to enable the EPEL (Extra Packages for Enterprise Linux) repository first:
       sudo yum install epel-release
    • Then install iftop:
       sudo yum install iftop
  2. For Fedora:
     sudo dnf install iftop

On Arch Linux:

  1. Install iftop using pacman:
     sudo pacman -S iftop

On openSUSE:

Install iftop using zypper:

sudo zypper install iftop

Verification:

After installation, you can verify that iftop is installed by running:

iftop -h

This should display the help message for iftop, indicating that the installation was successful.

If you encounter any issues or need to install from source, you can download the source code from the official iftop website and follow the instructions provided there.

Was this article helpful?
YesNo