Updated: 9 October 2026 · Applies to: usbutils 017 to 019 and util-linux 2.37 to 2.41 on Debian 13, Ubuntu 24.04 and 26.04, AlmaLinux 10 and Rocky Linux 9

To list all USB devices in Linux, run lsusb. To find which disk is your USB drive, run lsblk -o NAME,TRAN,SIZE,MODEL,MOUNTPOINTS and look for usb in the TRAN column: that row's NAME (for example sdb) is the device, /dev/sdb, and its partitions are /dev/sdb1, /dev/sdb2 and so on.

lsusb
lsblk -o NAME,TRAN,SIZE,MODEL,MOUNTPOINTS

Below are both commands with real output, plus the kernel log, stable /dev/disk/by-id names and how to mount the drive on a server.

1. List all USB devices with lsusb

lsusb is in the usbutils package. It was not installed in the minimal Debian, Ubuntu, AlmaLinux and Rocky Linux images we tested, so install it first if the command is missing:

sudo apt install usbutils     # Debian, Ubuntu
sudo dnf install usbutils     # AlmaLinux, Rocky Linux, RHEL, Fedora

Output on our test VPS (Debian 13, usbutils 018):

$ lsusb
Bus 001 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 002: ID 0627:0001 Adomax Technology Co., Ltd QEMU Tablet

Each line is one device: the bus and device number, then ID vendor:product in hexadecimal and the name from the USB ID database. The "root hub" lines are the USB controllers themselves. A virtual server has no physical USB ports, which is why this VPS only shows a virtual tablet; on a PC or a dedicated server your keyboard, mouse and USB drives appear here too.

Useful options:

  • lsusb -t: shows the devices as a tree, with the speed and the driver of each interface. A USB stick or disk uses the usb-storage or uas driver; keyboards and mice use usbhid:
    $ lsusb -t
    /:  Bus 001.Port 001: Dev 001, Class=root_hub, Driver=uhci_hcd/2p, 12M
        |__ Port 001: Dev 002, If 0, Class=Human Interface Device, Driver=usbhid, 12M
  • lsusb -d 0627:0001 or lsusb -s 001:002: show one device by its ID or by bus and device number.
  • sudo lsusb -v -d 0627:0001: all descriptors of that device (USB version, maximum power, interface class).
  • usb-devices (also in usbutils): a text summary per device with manufacturer, product, serial number and driver.

2. Find the USB drive name with lsblk

lsusb tells you a drive is connected but not its /dev name. lsblk (part of util-linux) does:

$ lsblk -o NAME,TRAN,SIZE,TYPE,MODEL,MOUNTPOINTS
NAME   TRAN  SIZE TYPE MODEL            MOUNTPOINTS
sda    ata    50G disk QEMU HARDDISK
|-sda1      48.8G part
`-sda2       1.2G part                  [SWAP]

TRAN is the transport. The system disk of this VPS shows ata; a USB stick or USB disk shows usb, so with a drive plugged in you see a second disk such as sdb with TRAN usb and its partitions below it. To print only USB disks:

lsblk -d -o NAME,TRAN,SIZE,MODEL | grep -w usb

Other columns that help: HOTPLUG (1 for removable or hotplug devices such as USB), FSTYPE and LABEL (filesystem and its name) and SERIAL. lsblk --list-columns shows them all. Always check the SIZE and MODEL before you format or write to a disk: picking the wrong sdX destroys data.

3. Watch the kernel log while you plug it in

If several disks look alike, watch the kernel messages and then connect the drive:

sudo dmesg -w          # or: sudo journalctl -k -f

The kernel reports the new USB device, then the disk name in square brackets on a line ending in Attached SCSI removable disk or Attached SCSI disk, for example [sdb]. Press Ctrl+C to stop watching. sudo dmesg | grep -i usb shows the USB messages already logged since boot.

4. Use a stable name: /dev/disk/by-id

Names such as sdb are given in the order disks appear, so the same stick can be sdb today and sdc tomorrow. udev also creates links that include the model and serial number. In the udev 257 rules on Debian 13, USB disks get links starting with usb-:

ls -l /dev/disk/by-id/ | grep usb

Each link points to the current sdX name. Use these links in scripts, or the filesystem UUID from sudo blkid in /etc/fstab.

5. Other ways to see the device

  • sudo fdisk -l: every disk with its size, model and partition table.
  • sudo blkid: partitions with their filesystem type, label and UUID.
  • df -h or findmnt: only filesystems that are already mounted, with their mount points. See findmnt examples.

6. Mount the USB drive

A desktop mounts a USB drive by itself: udisks uses /media/USERNAME/LABEL on Debian and Ubuntu and /run/media/USERNAME/LABEL on Fedora and the RHEL family. A server does not, so mount it by hand (replace sdb1 with your partition):

sudo mkdir -p /mnt/usb
sudo mount /dev/sdb1 /mnt/usb
ls /mnt/usb
sudo umount /mnt/usb      # before you unplug it

To format or partition a drive, see how to partition and mount a new disk with parted and, if fdisk fails on a USB disk, fdisk: Unable to write: Bad file descriptor. To control USB storage on a server, see make USB storage read-only or block it with USBGuard and run a script when a USB device is attached.

Official documentation: lsblk(8) and lsusb(8).

Ucartz services for this topic

Was this answer helpful? 0 Users Found This Useful (0 Votes)