Low Orbit Flux Logo 2 F

Linux Command - lshw

The Linux lshw command is used to list information about the hardware on the system.

NOTE - run as root for permission to query all hardware info

lshw                       # basic usage, dumps ton of hardware information
lshw -short                # nice short output
lshw -json                 # JSON output
lshw -c disk -c storage    # all disks and storage controllers
lshw -html -class network  # lists all network interfaces in HTML

-class class Only show the given class of hardware. class can be found using lshw -short or lshw -businfo.
-C class Alias for -class class.
-short Outputs the device tree showing hardware paths, very much like the output of HP-UX’s ioscan.
-html Outputs the device tree as an HTML page.
-xml Outputs the device tree as an XML tree.
-json Outputs the device tree as a JSON object (JavaScript Object Notation).
-X Launch the X11 GUI (if available).
-businfo Outputs the device list showing bus information, detailing SCSI, USB, IDE and PCI addresses.
-sanitize Remove potentially sensitive information from output (IP addresses, serial numbers, etc.).
-numeric Also display numeric IDs (for PCI and USB devices).
-notime Exclude volatile attributes (timestamps) from output.
-dump filename Display output and dump collected information into a file (SQLite database).