Home > Package & System Management > lsusb

lsusb: List USB Devices

Lists information about USB devices connected to the system. It displays details such as USB bus, device ID, manufacturer, product name, and speed, making it useful for troubleshooting and identifying USB devices.

Overview

lsusb displays information about USB devices and USB controllers connected to a Linux system. This information can be used for hardware diagnostics, driver troubleshooting, and identifying specific USB devices.

Key Features

  • Outputs a list of all connected USB devices
  • Displays Device ID (Vendor ID:Product ID)
  • Provides manufacturer and product name information
  • Checks USB version and speed information
  • Supports verbose output

Common Options

These are the options frequently used with the lsusb command.

Displaying and Filtering Information

Generated command:

Try combining the commands.

Description:

`lsusb` Executes the command.

Combine the above options to virtually execute commands with AI.

Usage Examples

Here are various examples of how to use the lsusb command.

View List of All USB Devices

lsusb

Outputs a brief summary of all USB devices connected to the system.

View Detailed Information of USB Devices

lsusb -v | less

Outputs very detailed technical information for each USB device. The output can be lengthy, so it's recommended to use it with `less`.

Search for Devices by Specific Vendor/Product ID

lsusb -d 046d:c077

This example searches for a specific Logitech (046d) mouse (c077). Actual device IDs can be found in the default `lsusb` output.

View USB Device Connection Tree Structure

lsusb -t

Visualizes the connection relationships between USB hubs and devices in a tree format.

Search for Devices by Name

lsusb | grep -i "webcam"

Use `grep` in conjunction with `lsusb` to find devices containing specific strings (e.g., 'Webcam') in the output.

Installation

lsusb is typically part of the `usbutils` package. If it's not installed by default on your Linux distribution, you can install it using the following commands.

Debian/Ubuntu

sudo apt update && sudo apt install usbutils

Install `usbutils` using the APT package manager.

Fedora/RHEL/CentOS

sudo dnf install usbutils
# or
sudo yum install usbutils

Install `usbutils` using the DNF or YUM package manager.

Tips & Notes

Useful tips and additional considerations when using lsusb.

Filtering Output

When lsusb output is extensive, you can easily filter for desired information using the `grep` command. For example, to see only devices from a specific manufacturer, use `lsusb | grep "Logitech"`.

  • Use `lsusb | grep "[keyword]"` to search for specific devices.
  • Use `lsusb -v | grep "[information]"` to search for specific fields within verbose output.

Permissions

Generally, `lsusb` runs without `sudo`. However, to view very detailed information with the `-v` option or access certain devices, running with `sudo` might be necessary to obtain more comprehensive data.

Related Commands

To check information about other hardware components in your system besides USB devices, you can use the following commands:

  • `lspci`: Check PCI device information.
  • `lshw`: Check all hardware information (very detailed).
  • `dmesg`: Check kernel messages (including USB connection/disconnection events).
  • `udevadm info --query=all --name=/dev/bus/usb/[bus_number]/[device_number]`: Check detailed udev attributes for a specific USB device.

Same category commands