{
    "mode": "man",
    "parameter": "lshw",
    "section": "1",
    "url": "https://www.chedong.com/phpMan.php/man/lshw/1/json",
    "generated": "2026-06-16T10:10:37Z",
    "synopsis": "lshw [ -version ]\nlshw [ -help ]\nlshw [ -X ]\nlshw  [   [  -html ]  [ -short ]  [ -xml ]  [ -json ]  [ -businfo ]  ]  [ -dump filename ]  [\n-class class... ]  [ -disable test... ]  [ -enable test... ]  [ -sanitize ]  [ -numeric ]   [\n-quiet ]  [ -notime ]",
    "sections": {
        "NAME": {
            "content": "lshw - list hardware\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "lshw [ -version ]\n\nlshw [ -help ]\n\nlshw [ -X ]\n\nlshw  [   [  -html ]  [ -short ]  [ -xml ]  [ -json ]  [ -businfo ]  ]  [ -dump filename ]  [\n-class class... ]  [ -disable test... ]  [ -enable test... ]  [ -sanitize ]  [ -numeric ]   [\n-quiet ]  [ -notime ]\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "lshw is a small tool to extract detailed information on the hardware configuration of the ma-\nchine. It can report exact memory configuration, firmware version,  mainboard  configuration,\nCPU  version and speed, cache configuration, bus speed, etc. on DMI-capable x86 or IA-64 sys-\ntems and on some PowerPC machines (PowerMac G4 is known to work).\n\nIt currently supports DMI (x86 and IA-64 only),  OpenFirmware  device  tree  (PowerPC  only),\nPCI/AGP, CPUID (x86), IDE/ATA/ATAPI, PCMCIA (only tested on x86), SCSI and USB.\n",
            "subsections": [
                {
                    "name": "-version",
                    "content": "Displays the version of lshw and exits.\n\n-help  Displays the available command line options and quits.\n\n-X     Launch the X11 GUI (if available).\n\n-html  Outputs the device tree as an HTML page.\n\n-xml   Outputs the device tree as an XML tree.\n\n-json  Outputs the device tree as a JSON object (JavaScript Object Notation).\n\n-short Outputs  the  device tree showing hardware paths, very much like the output of HP-UX's\nioscan.\n"
                },
                {
                    "name": "-businfo",
                    "content": "Outputs the device list showing bus information, detailing SCSI, USB, IDE and PCI  ad-\ndresses.\n\n-dump filename\nDisplay output and dump collected information into a file (SQLite database).\n\n-class class\nOnly  show  the  given class of hardware. class can be found using lshw -short or lshw\n-businfo.\n\n-C class\nAlias for -class class.\n\n-enable test\n\n-disable test\nEnables or disables a test. test can be dmi (for DMI/SMBIOS  extensions),  device-tree\n(for  OpenFirmware  device tree), spd (for memory Serial Presence Detect), memory (for\nmemory-size guessing heuristics), cpuinfo (for kernel-reported CPU  detection),  cpuid\n(for CPU detection), pci (for PCI/AGP access), isapnp (for ISA PnP extensions), pcmcia\n(for PCMCIA/PCCARD), ide (for IDE/ATAPI), usb (for USB  devices),scsi  (for  SCSI)  or\nnetwork (for network interfaces detection).\n\n-quiet Don't display status.\n"
                },
                {
                    "name": "-sanitize",
                    "content": "Remove  potentially  sensitive  information from output (IP addresses, serial numbers,\netc.).\n"
                },
                {
                    "name": "-numeric",
                    "content": "Also display numeric IDs (for PCI and USB devices).\n"
                },
                {
                    "name": "-notime",
                    "content": "Exclude volatile attributes (timestamps) from output.\n"
                }
            ]
        },
        "BUGS": {
            "content": "lshw currently does not detect Firewire(IEEE1394) devices.\n\nNot all architectures supported by GNU/Linux are fully supported (e.g.  CPU detection).\n\n\"Virtual\" SCSI interfaces used for SCSI emulation over IDE are not reported correctly yet.\n",
            "subsections": []
        },
        "NOTES": {
            "content": "lshw must be run as super user or it will only report partial information.\n",
            "subsections": []
        },
        "FILES": {
            "content": "/usr/local/share/pci.ids\n\n/usr/share/pci.ids\n\n/etc/pci.ids\n\n/usr/share/hwdata/pci.ids\nA list of all known PCI ID's (vendors, devices, classes and subclasses).  If  compiled\nwith zlib support, lshw will look for pci.ids.gz first, then for pci.ids.\n\n/proc/bus/pci/*\nUsed to access the configuration of installed PCI buses and devices.\n\n/proc/ide/*\nUsed to access the configuration of installed IDE buses and devices.\n\n/proc/scsi/*, /dev/sg*\nUsed to access the configuration of installed SCSI devices.\n\n/dev/cpu/*/cpuid\nUsed on x86 platforms to access CPU-specific configuration.\n\n/proc/device-tree/*\nUsed on PowerPC platforms to access OpenFirmware configuration.\n\n/proc/bus/usb/*\nUsed to access the configuration of installed USB buses and devices.\n\n/sys/* Used on 2.6 kernels to access hardware/driver configuration information.\n",
            "subsections": []
        },
        "EXAMPLES": {
            "content": "lshw -short\nLists hardware in a compact format.\n\nlshw -class disk -class storage\nLists all disks and storage controllers in the system.\n\nlshw -html -class network\nLists all network interfaces in HTML.\n\nlshw -disable dmi\nDon't use DMI to detect hardware.\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "/proc/*, linuxinfo(1), lspci(8), lsusb(8)\n",
            "subsections": []
        },
        "COPYING": {
            "content": "lshw is distributed under the GNU GENERAL PUBLIC LICENSE (GPL) version 2.\n",
            "subsections": []
        },
        "AUTHOR": {
            "content": "lshw is maintained by Lyonel Vincent <lyonel@ezix.org>.\n",
            "subsections": []
        },
        "OTHER INFO": {
            "content": "The webpage for lshw is at\n<URL:http://lshw.ezix.org/>\n\n$Rev$                                    15 October 2020                                  LSHW(1)",
            "subsections": []
        }
    },
    "summary": "lshw - list hardware",
    "flags": [
        {
            "flag": "",
            "long": null,
            "arg": null,
            "description": "Displays the version of lshw and exits. -help Displays the available command line options and quits. -X Launch the X11 GUI (if available). -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). -short Outputs the device tree showing hardware paths, very much like the output of HP-UX's ioscan."
        },
        {
            "flag": "",
            "long": null,
            "arg": null,
            "description": "Outputs the device list showing bus information, detailing SCSI, USB, IDE and PCI ad- dresses. -dump filename Display output and dump collected information into a file (SQLite database). -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. -enable test -disable test Enables or disables a test. test can be dmi (for DMI/SMBIOS extensions), device-tree (for OpenFirmware device tree), spd (for memory Serial Presence Detect), memory (for memory-size guessing heuristics), cpuinfo (for kernel-reported CPU detection), cpuid (for CPU detection), pci (for PCI/AGP access), isapnp (for ISA PnP extensions), pcmcia (for PCMCIA/PCCARD), ide (for IDE/ATAPI), usb (for USB devices),scsi (for SCSI) or network (for network interfaces detection). -quiet Don't display status."
        },
        {
            "flag": "",
            "long": null,
            "arg": null,
            "description": "Remove potentially sensitive information from output (IP addresses, serial numbers, etc.)."
        },
        {
            "flag": "",
            "long": null,
            "arg": null,
            "description": "Also display numeric IDs (for PCI and USB devices)."
        },
        {
            "flag": "",
            "long": null,
            "arg": null,
            "description": "Exclude volatile attributes (timestamps) from output."
        }
    ],
    "examples": [
        "lshw -short",
        "Lists hardware in a compact format.",
        "lshw -class disk -class storage",
        "Lists all disks and storage controllers in the system.",
        "lshw -html -class network",
        "Lists all network interfaces in HTML.",
        "lshw -disable dmi",
        "Don't use DMI to detect hardware."
    ],
    "see_also": [
        {
            "name": "linuxinfo",
            "section": "1",
            "url": "https://www.chedong.com/phpMan.php/man/linuxinfo/1/json"
        },
        {
            "name": "lspci",
            "section": "8",
            "url": "https://www.chedong.com/phpMan.php/man/lspci/8/json"
        },
        {
            "name": "lsusb",
            "section": "8",
            "url": "https://www.chedong.com/phpMan.php/man/lsusb/8/json"
        }
    ],
    "tldr": {
        "source": "official",
        "description": "List detailed information about hardware configurations as root user.",
        "examples": [
            {
                "description": "Launch the X11 GUI (if available)",
                "command": "sudo lshw -X"
            },
            {
                "description": "List all hardware in tabular format",
                "command": "sudo lshw -short"
            },
            {
                "description": "List multiple class of hardware (all disks and storage controllers) in tabular format",
                "command": "sudo lshw {{-c|-class}} disk {{-c|-class}} storage -short"
            },
            {
                "description": "Save all network interfaces to an HTML/XML/JSON file",
                "command": "sudo lshw {{-c|-class}} network -{{html|xml|json}} > interfaces{{.html|.xml|.json}}"
            },
            {
                "description": "List network interfaces without revealing sensitive information (IP addresses, serial numbers, etc.)",
                "command": "sudo lshw {{-c|-class}} network -sanitize"
            },
            {
                "description": "List a particular class of hardware",
                "command": "sudo lshw {{-c|-class}} {{system|bridge|memory|processor|address|storage|disk|tape|bus|network|display|input|printer|multimedia|communication|power|volume|generic}}"
            }
        ]
    }
}