Install duf on Ubuntu 20.04

Install duf on Ubuntu 20.04

The duf is a command line tool which shows disk space usage of the system. The duf can be used as an alternative to the df command. The duf can display results in the table or in JSON format.

This tutorial explains how to install duf on Ubuntu 20.04.

Install duf

Get the latest version tag of duf release and assign it to variable:

DUF_VERSION=$(curl -s "" | grep -Po '"tag_name": "v\K[0-9.]+')

Next, download Debian package (.deb) from releases page of the duf repository:

curl -Lo duf.deb "${DUF_VERSION}_linux_amd64.deb"

Install duf:

sudo apt install -y ./duf.deb

Once installation is completed, we can check duf version:

duf -version

The .deb file is no longer needed, remove it:

rm -rf duf.deb

Testing duf

Run the duf command without arguments to see all mounted filesystems:

Get list of all mounted filesystems using duf on Ubuntu

Uninstall duf

If you want to completely remove duf, run the following command:

sudo apt purge --autoremove -y duf

Leave a Comment

Cancel reply

Your email address will not be published.