usb-devices(1)

๐Ÿ“ฆ
version 020 ยท 4 versions
, in alpine 3.22, alpine 3.23, alpine 3.24, arch rolling, centos-stream 10, debian trixie, fedora 43, fedora 44, nixos 26.05, ubuntu questing, ubuntu resolute, ubuntu stonking

โœจ usb-devices(1) โœจ Linux USB Utilities ๐Ÿ’–

๐Ÿ’… NAME

usb-devices โ€” print USB device details ๐ŸŽ€

๐Ÿงš SYNOPSIS

usb-devices

๐ŸŒธ DESCRIPTION

okay so usb-devices is a shell script ๐Ÿš that lets you peek at the USB buses in your system and every device plugged into them ๐Ÿ”Œโœจ

its output is basically a copy of the usb/devices file ๐Ÿ“„ which you can normally find under /proc/bus (if usbfs is mounted) or under /sys/kernel/debug (if debugfs is mounted there). the script is mainly for when that file is nowhere to be found ๐Ÿ™ˆ

bestie, the big difference: this script only shows active interfaces (the ones marked with a "*" in the usb/devices file) plus their endpoints ๐Ÿฆ‹

ngl, sorting can be different and the output format can look different too, so don't be surprised if it doesn't match the file exactly ๐Ÿ’€

๐Ÿ‘‘ RETURN VALUE

if sysfs is not mounted, you get a non-zero exit code ๐Ÿ˜ญ so no sysfs, no vibes.

๐ŸŽ€ FILES

  • /sys/bus/usb/devices/usb*
    • this is the part of the sysfs tree the script walks through to put together everything it prints ๐ŸŒˆ
  • /proc/bus/usb/devices
    • where the usb/devices file normally lives on Linux kernels before 2.6.31, if usbfs is mounted ๐Ÿ“
  • /sys/kernel/debug/usb/devices
    • where the usb/devices file normally lives on Linux kernel 2.6.31 and later, if debugfs is mounted ๐Ÿ’œ

๐Ÿฆ‹ SEE ALSO

lsusb(8), usbview(8). go check those out, they're iconic ๐Ÿ”ฅ

๐Ÿซถ AUTHORS

Greg Kroah-Hartman <greg@kroah.com>

Randy Dunlap <rdunlap@xenotime.net>

Frans Pop <elendil@planet.nl>


bestie, this page is from usbutils ๐Ÿ’– dated 23 June 2009 ๐Ÿ“… and it's a usb-devices(1) page, so you're all set ๐ŸŒธ love you, mwah! ๐Ÿ˜˜โœจ

๐Ÿ“ฆ where this page comes from