Operations 7 min read

Mastering lsusb: List and Analyze USB Devices on CentOS 7

This guide shows how to install usbutils, use lsusb and its options to list USB devices, display detailed information, view hierarchical structures, and filter storage devices on a CentOS 7 system.

Liangxu Linux
Liangxu Linux
Liangxu Linux
Mastering lsusb: List and Analyze USB Devices on CentOS 7

Install usbutils

CentOS 7 does not include lsusb by default. Install it with:

yum -y install usbutils

List USB devices

Run lsusb to display each device’s bus number, device number, vendor ID, product ID and description.

Bus 001 Device 010: ID 0bda:0129 Realtek Semiconductor Corp. RTS5129 Card Reader Controller
Bus 001 Device 055: ID 0951:1665 Kingston Technology Digital DataTraveler SE9 64GB
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 003: ID 0e0f:0002 VMware, Inc. Virtual USB Hub
Bus 002 Device 002: ID 0e0f:0003 VMware, Inc. Virtual Mouse
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub

Field explanation

Bus 001

– identifier of the USB controller (use lspci | grep USB to list all controllers). Device 055 – system‑assigned device number. ID – vendor and product identifiers.

Text after the IDs – manufacturer and product name.

Tree view of USB topology

Use the -t option for a hierarchical display. The speed suffixes indicate the bus speed (12M = USB 1.1, 480M = USB 2.0, 5000M = USB 3.0).

/:  Bus 04.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/4p, 5000M
/:  Bus 03.Port 1: Dev 1, Class=root_hub, Driver=xhci_hcd/4p, 480M
    |__ Port 1: Dev 2, If 0, Class=Mass Storage, Driver=usb-storage, 480M
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=uhci_hcd/2p, 12M
    |__ Port 1: Dev 2, If 0, Class=Human Interface Device, Driver=usbhid, 12M
    |__ Port 2: Dev 3, If 0, Class=Hub, Driver=hub/7p, 12M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=ehci-pci/6p, 480M

Verbose device information

Use -v to show full descriptors (device, configuration, interface, endpoint). Pipe to less for paging: lsusb -v | less Typical fields include bLength, bDescriptorType, bcdUSB, idVendor, idProduct, class codes, max packet size, power consumption, etc.

Count connected devices

List device nodes under /dev/bus/usb to see how many devices are present:

find /dev/bus/usb

Identify mass‑storage devices

Filter verbose output for the Mass Storage class and vendor IDs: lsusb -v | grep -E 'idVendor|Mass Storage' This isolates entries such as:

idVendor           0x0951 Kingston Technology
bInterfaceClass    8 Mass Storage

Query a single device

Use the -D option with the device node path to retrieve its full descriptor set:

lsusb -D /dev/bus/usb/001/056
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.

Liangxu Linux
Written by

Liangxu Linux

Liangxu, a self‑taught IT professional now working as a Linux development engineer at a Fortune 500 multinational, shares extensive Linux knowledge—fundamentals, applications, tools, plus Git, databases, Raspberry Pi, etc. (Reply “Linux” to receive essential resources.)

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.