Operations 5 min read

How to List All Connected Disks on Ubuntu with lsblk, fdisk, and GUI Tools

This guide walks you through multiple ways to enumerate every storage device attached to an Ubuntu system—including command‑line utilities like lsblk, fdisk, and parted as well as graphical tools such as GNOME Disks and GParted—while showing how to filter out unwanted loop or CD/DVD entries.

ITPUB
ITPUB
ITPUB
How to List All Connected Disks on Ubuntu with lsblk, fdisk, and GUI Tools

In this tutorial you will learn how to list every disk (SSD, HDD, USB, etc.) connected to an Ubuntu machine using both command‑line utilities and graphical applications.

Using lsblk

Run the basic command: sudo lsblk The TYPE column indicates whether an entry is a whole disk or a partition. By default the output also shows loop devices created by snap packages, which can be noisy.

Hide loop devices with the -e7 option: sudo lsblk -e7 You can further hide CD/DVD devices by adding -e11: sudo lsblk -e7 -e11 Alternatively, filter with grep: sudo lsblk | grep -v '^loop' To display vendor and model information, use the SCSI view:

sudo lsblk --scsi

Using fdisk

List all disks with sizes and partitions: sudo fdisk -l If you know a device name (e.g., /dev/sdb), query it directly: sudo fdisk -l /dev/sdb Multiple devices can be inspected in one call:

sudo fdisk -l /dev/sda /dev/sdb

Using parted

First install parted if it is not present: sudo apt install parted -y Then list all disks: sudo parted -l The output format mirrors fdisk but automatically omits loop devices.

Graphical tools

GNOME Disks

Open the application from the Applications menu. The left pane shows every connected storage device; selecting a disk reveals its size, partitions, and detailed information on the right.

GParted

Install GParted if needed: sudo apt install gparted -y Launch it (you will be prompted for your password). Use the drop‑down menu in the top‑right corner to choose a disk; the partitions of the selected disk are displayed below.

These methods cover both command‑line and GUI approaches for enumerating disks on Ubuntu, allowing you to choose the most convenient tool for your workflow.

Original Source

Signed-in readers can open the original source through BestHub's protected redirect.

Sign in to view source
Republication Notice

This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactadmin@besthub.devand we will review it promptly.

LinuxUbuntufdiskpartedlsblkdisk-listing
ITPUB
Written by

ITPUB

Official ITPUB account sharing technical insights, community news, and exciting events.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.