hwinfo (Hardware Info) – A Nifty Tool To Detect System Hardware Information On Linux

hwinfo stands for hardware information tool is another great utility that used to probe for the hardware present in the system and display detailed information about varies hardware components in human readable format.

It reports information about CPU, RAM, keyboard, mouse, graphics card, sound, storage, network interface, disk, partition, bios, and bridge, etc,., This tool could display more detailed information among others like lshw, dmidecode, inxi, etc,.

hwinfo uses libhd library libhd.so to gather hardware information on the system. This tool especially designed for openSUSE system, later other distributions are included the tool into their official repository.

Also read a following articles which is related to Linux hardware.

Suggested Read :
(#) LSHW (Hardware Lister) – A Nifty Tool To Get A Hardware Information On Linux
(#) inxi – A Great Tool to Check Hardware Information on Linux
(#) Dmidecode – Easy Way To Get Linux System Hardware Information
(#) Neofetch – Shows Linux System Information With ASCII Distribution Logo
(#) ScreenFetch – Fetch Linux System Information on Terminal with Distribution ASCII art logo
(#) 16 Methods To Check If A Linux System Is Physical or Virtual Machine

hwinfo will display the following information.

  • CPU : manufacturer, model, frequency
  • Motherboard : manufacturer, model, BIOS version, on-board controller
  • RAM : RAM size, RAM type (FP, EDO, SDRAM, DDRAM)
  • Hard disk controller : SCSI, IDE, on-board/card, model, BIOS version, chipset
  • Hard disks : type, manufacturer, model, size, bus system (SCSI, IDE), partitioning
  • CD-ROM drives : type, manufacturer, model, speed, internal/external, parallel port?
  • Other media : CD writer, streamer (model, manufacturer, SCSI/EIDE/floppy streamer, capacity), ZIP drives, Jaz drives, MO drives, flopticals
  • Graphics card : model, manufacturer, chipset, memory (DRAM, VRAM), memory size
  • Other peripherals : printer, parallel ports, serial ports, modem, ISDN card

For Arch Linux based systems the Neofetch is available in distribution official repository, so use Pacman command to install it.

$ sudo pacman -S hwinfo

For Fedora 25 users, add following third-party repository and use dnf command to install Neofetch.

$ sudo dnf config-manager --add-repo http://download.opensuse.org/repositories/home:/zhonghuaren/Fedora_25/home:zhonghuaren.repo
$ sudo dnf makecache
$ sudo dnf install hwinfo

For Fedora 26 users, add following third-party repository and use dnf command to install Neofetch.

$ sudo dnf config-manager --add-repo http://download.opensuse.org/repositories/home:/zhonghuaren/Fedora_26/home:zhonghuaren.repo
$ sudo dnf makecache
$ sudo dnf install hwinfo

For CentOS/RHEL 6 users, add following third-party repository and use YUM command to install Neofetch.

$ sudo rpm -Uvh http://mirror.ghettoforge.org/distributions/gf/gf-release-latest.gf.el6.noarch.rpm
$ sudo yum makecache
$ sudo yum install hwinfo

For CentOS/RHEL 7 users, add following third-party repository and use YUM command to install Neofetch.

$ sudo rpm -Uvh http://mirror.ghettoforge.org/distributions/gf/gf-release-latest.gf.el7.noarch.rpm
$ sudo yum makecache
$ sudo yum install hwinfo

For Debian/Ubuntu based systems the Neofetch package is available in distribution official repository, so use APT or APT-GET command to install it.

$ sudo apt-get install hwinfo

For openSUSE systems the Neofetch package is available in distribution official repository, so use Zypper command to install it.

$ sudo zypper install hwinfo

Common Syntax for hwinfo

hwinfo [OPTIONS] [HARDWARE_ITEM]

Available hardware items are : all, arch, bios, block, bluetooth, braille, bridge, camera, cdrom, chipcard, cpu, disk, dsl, dvb, fingerprint, floppy, framebuffer, gfxcard, hub, ide, isapnp, isdn, joystick, keyboard, memory, modem, monitor, mouse, netcard, network, partition, pci, pcmcia, pcmcia-ctrl, pppoe, printer, redasd, reallyall, scanner, scsi, smp, sound, storage-ctrl, sys, tape, tv, uml, usb, usb-ctrl, vbe, wlan, xen, zip

Display All Information

Run hwinfo command without any arguments that display detailed information about all hardware units but it would be very difficult to understand since it’s showing indepth details about hardware components.

$ hwinfo | more
============ start debug info ============
libhd version 21.38u (x86-64) [7688]
using /var/lib/hardware
kernel version is 4.12
----- /proc/cmdline -----
  BOOT_IMAGE=/boot/vmlinuz-linux root=UUID=82e7058a-e253-4e6e-af88-2a902036ed42 rw console=tty0 console=ttyS0,115200 quiet
----- /proc/cmdline end -----
debug = 0xff7ffff7
probe = 0x15938fcdaa17fcf9fffe (+memory +pci +isapnp +net +floppy +misc +misc.serial +misc.par +misc.floppy +serial +cpu +bios +monitor +mouse
+scsi +usb -usb.mods +modem +modem.usb +parallel +parallel.lp +parallel.zip -isa -isa.isdn +isdn +kbd +prom +sbus +int +braille +braille.alva
+braille.fhp +braille.ht -ignx11 +sys -bios.vbe -isapnp.old -isapnp.new -isapnp.mod +braille.baum -manual +fb +pppoe -scan +pcmcia +fork -par
allel.imm +s390 +cpuemu -sysfs -s390disks +udev +block +block.cdrom +block.part +edd +edd.mod -bios.ddc -bios.fb -bios.mode +input +block.mods
+bios.vesa -cpuemu.debug -scsi.noserial +wlan -bios.crc -hal +bios.vram +bios.acpi -bios.ddc.ports=0 +modules.pata -net.eeprom +x86emu=dump -
max -lxrc)
shm: attached segment 524288 at 0x7fc70f0ea000
>> hal.1: read hal data
>> floppy.1: get nvram
>> floppy.2: klog info
>> bios.1: cmdline
>> bios.1.1: apm
>> bios.2: ram
  bios: 0 disks
>> bios.2: rom
>> bios.3: smp
----- BIOS data 0x00400 - 0x004ff -----
  400  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  "................"
  410  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  "................"
  420  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  "................"
  430  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  "................"
  440  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  "................"
  450  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  "................"
  460  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  "................"
  470  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  "................"
  480  00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00  "................"

Display Summary Information

This will print a summarize report of hardware components.

$ hwinfo --short
cpu:
                       Intel Core Processor (Haswell, no TSX), 2394 MHz
keyboard:
  /dev/input/event0    AT Translated Set 2 keyboard
  /dev/ttyS0           serial console
mouse:
  /dev/input/mice      Adomax QEMU USB Tablet
  /dev/input/mice      VirtualPS/2 VMware VMMouse
  /dev/input/mice      VirtualPS/2 VMware VMMouse
graphics card:
                       Red Hat QEMU Virtual Machine
storage:
                       Floppy disk controller
                       Red Hat Qemu virtual machine
                       Virtio Storage 0
network:
  eth0                 Virtio Ethernet Card 0
network interface:
  lo                   Loopback network interface
  eth0                 Ethernet network interface
disk:
  /dev/vda             Disk
partition:
  /dev/vda1            Partition
usb controller:
                       Red Hat QEMU Virtual Machine
bios:
                       BIOS
bridge:
                       Red Hat Qemu virtual machine
                       Red Hat Qemu virtual machine
                       Red Hat Qemu virtual machine
hub:
                       Linux Foundation 1.1 root hub
memory:
                       Main Memory
unknown:
                       FPU
                       DMA controller
                       PIC
                       Keyboard controller
                       Red Hat Virtio network device
                       Red Hat Virtio memory balloon
                       Red Hat Virtio block device
                       Virtio Unclassified device
                       Serial controller

Display CPU Information

To display detailed CPU information alone, use --cpu option with hwinfo command. It includes, Processor model, system architecture, clock speed, and cpu cache size, etc.

$ hwinfo --cpu
01: None 00.0: 10103 CPU
  [Created at cpu.457]
  Unique ID: rdCR.j8NaKXDZtZ6
  Hardware Class: cpu
  Arch: X86-64
  Vendor: "GenuineIntel"
  Model: 6.60.1 "Intel Core Processor (Haswell, no TSX)"
  Features:
fpu,vme,de,pse,tsc,msr,pae,mce,cx8,apic,sep,mtrr,pge,mca,cmov,pat,pse36,clflush,mmx,fxsr,sse,sse2,ss,syscall,nx,pdpe1gb,rdtscp,lm,constant_tsc,rep_good,nopl,cpuid,pni,
pclmulqdq,vmx,ssse3,fma,cx16,pcid,sse4_1,sse4_2,x2apic,movbe,popcnt,tsc_deadline_timer,aes,xsave,avx,f16c,rdrand,hypervisor,lahf_lm,abm,tpr_shadow,vnmi,flexpriority,ep
t,vpid,fsgsbase,bmi1,avx2,smep,bmi2,erms,invpcid,xsaveopt
  Clock: 2394 MHz
  BogoMips: 4790.44
  Cache: 4096 kb
  Config Status: cfg=new, avail=yes, need=no, active=unknown

Display Hard Drive Controllers

To display detailed Hard drive controllers information, use --storage option with hwinfo command. It includes, Vendor name, model, device info, I/O port status, etc,.,

$ hwinfo --storage
07: None 00.0: 0102 Floppy disk controller
  [Created at misc.281]
  Unique ID: rdCR.3wRL2_g4d2B
  Hardware Class: storage
  Model: "Floppy disk controller"
  I/O Port: 0x00 (rw)
  I/O Port: 0x00 (rw)
  I/O Port: 0x00 (rw)
  DMA: 2
  Config Status: cfg=new, avail=yes, need=no, active=unknown

11: PCI 01.1: 0101 IDE interface
  [Created at pci.378]
  Unique ID: mnDB.3sKqaxiizg6
  SysFS ID: /devices/pci0000:00/0000:00:01.1
  SysFS BusID: 0000:00:01.1
  Hardware Class: storage
  Model: "Red Hat Qemu virtual machine"
  Vendor: pci 0x8086 "Intel Corporation"
  Device: pci 0x7010 "82371SB PIIX3 IDE [Natoma/Triton II]"
  SubVendor: pci 0x1af4 "Red Hat, Inc"
  SubDevice: pci 0x1100 "Qemu virtual machine"
  Driver: "ata_piix"
  Driver Modules: "ata_piix"
  I/O Ports: 0x1f0-0x1f7 (rw)
  I/O Port: 0x3f6 (rw)
  I/O Ports: 0x170-0x177 (rw)
  I/O Port: 0x376 (rw)
  I/O Ports: 0xc0a0-0xc0af (rw)
  Module Alias: "pci:v00008086d00007010sv00001AF4sd00001100bc01sc01i80"
  Driver Info #0:
    Driver Status: ata_piix is active
    Driver Activation Cmd: "modprobe ata_piix"
  Driver Info #1:
    Driver Status: ata_generic is active
    Driver Activation Cmd: "modprobe ata_generic"
  Driver Info #2:
    Driver Status: pata_acpi is active
    Driver Activation Cmd: "modprobe pata_acpi"
  Config Status: cfg=new, avail=yes, need=no, active=unknown

17: Virtio 00.0: 0180 Storage controller
  [Created at pci.1631]
  Unique ID: sNGd.+FFPFBVXZu6
  Parent ID: 8otl.qHLOOfQ42uE
  SysFS ID: /devices/pci0000:00/0000:00:04.0/virtio1
  SysFS BusID: virtio1
  Hardware Class: storage
  Model: "Virtio Storage 0"
  Vendor: int 0x6014 "Virtio"
  Device: int 0x0002 "Storage 0"
  Driver: "virtio_blk"
  Driver Modules: "virtio_blk"
  Module Alias: "virtio:d00000002v00001AF4"
  Driver Info #0:
    Driver Status: virtio_blk is active
    Driver Activation Cmd: "modprobe virtio_blk"
  Config Status: cfg=new, avail=yes, need=no, active=unknown
  Attached to: #16 (SCSI storage controller)

Display Network Interface

To display detailed network interface information, use --network option with hwinfo command.

$ hwinfo --network
15: None 00.0: 10700 Loopback
  [Created at net.126]
  Unique ID: ZsBS.GQNx7L4uPNA
  SysFS ID: /class/net/lo
  Hardware Class: network interface
  Model: "Loopback network interface"
  Device File: lo
  Link detected: yes
  Config Status: cfg=new, avail=yes, need=no, active=unknown

16: None 00.0: 10701 Ethernet
  [Created at net.126]
  Unique ID: usDW.ndpeucax6V1
  Parent ID: vWuh.VIRhsc57kTD
  SysFS ID: /class/net/eth0
  SysFS Device Link: /devices/pci0000:00/0000:00:03.0/virtio0
  Hardware Class: network interface
  Model: "Ethernet network interface"
  Driver: "virtio_net"
  Driver Modules: "virtio_net"
  Device File: eth0
  HW Address: fa:16:3e:4e:c0:e5
  Permanent HW Address: fa:16:3e:4e:c0:e5
  Link detected: yes
  Config Status: cfg=new, avail=yes, need=no, active=unknown
  Attached to: #12 (Ethernet controller)

Display Network Card

To display detailed network card information, use --netcard option with hwinfo command.

$ hwinfo --netcard
18: Virtio 00.0: 0200 Ethernet controller
  [Created at pci.1631]
  Unique ID: vWuh.VIRhsc57kTD
  Parent ID: 3hqH.pkM7KXDR457
  SysFS ID: /devices/pci0000:00/0000:00:03.0/virtio0
  SysFS BusID: virtio0
  Hardware Class: network
  Model: "Virtio Ethernet Card 0"
  Vendor: int 0x6014 "Virtio"
  Device: int 0x0001 "Ethernet Card 0"
  Driver: "virtio_net"
  Driver Modules: "virtio_net"
  Device File: eth0
  HW Address: fa:16:3e:4e:c0:e5
  Permanent HW Address: fa:16:3e:4e:c0:e5
  Link detected: yes
  Module Alias: "virtio:d00000001v00001AF4"
  Driver Info #0:
    Driver Status: virtio_net is active
    Driver Activation Cmd: "modprobe virtio_net"
  Config Status: cfg=new, avail=yes, need=no, active=unknown
  Attached to: #9 (Ethernet controller)

Display Disk Information

To display detailed hard disk information, use --disk option with hwinfo command. It includes, Device file name, device file path, bois id, device number, etc.

$ hwinfo --disk
14: None 00.0: 10600 Disk
  [Created at block.245]
  Unique ID: KSbE.Fxp0d3BezAE
  Parent ID: sNGd.+FFPFBVXZu6
  SysFS ID: /class/block/vda
  SysFS BusID: virtio1
  SysFS Device Link: /devices/pci0000:00/0000:00:04.0/virtio1
  Hardware Class: disk
  Model: "Disk"
  Driver: "virtio-pci", "virtio_blk"
  Driver Modules: "virtio_pci", "virtio_blk"
  Device File: /dev/vda
  Device Files: /dev/vda, /dev/disk/by-path/pci-0000:00:04.0, /dev/disk/by-path/virtio-pci-0000:00:04.0
  Device Number: block 254:0-254:15
  BIOS id: 0x80
  Drive status: no medium
  Config Status: cfg=new, avail=yes, need=no, active=unknown
  Attached to: #11 (Storage controller)

Display Partition Information

To display detailed hard disk partition information, use --partition option with hwinfo command.

$ hwinfo --partition
15: None 00.0: 11300 Partition
  [Created at block.434]
  Unique ID: tyyG.SE1wIdpsiiC
  Parent ID: KSbE.Fxp0d3BezAE
  SysFS ID: /class/block/vda/vda1
  Hardware Class: partition
  Model: "Partition"
  Device File: /dev/vda1
  Device Files: /dev/vda1, /dev/disk/by-partuuid/ad63d4d2-01, /dev/disk/by-path/pci-0000:00:04.0-part1, /dev/disk/by-path/virtio-pci-0000:00:04.0-part1, /dev/disk/by-
uuid/82e7058a-e253-4e6e-af88-2a902036ed42
  Config Status: cfg=new, avail=yes, need=no, active=unknown
  Attached to: #14 (Disk)

Display USB Device Controller

To display detailed usb device information, use --usb option with hwinfo command.

$ hwinfo --usb
02: USB 00.0: 10a00 Hub
  [Created at usb.122]
  Unique ID: k4bc.lBczeyMQyT5
  SysFS ID: /devices/pci0000:00/0000:00:01.2/usb1/1-0:1.0
  SysFS BusID: 1-0:1.0
  Hardware Class: hub
  Model: "Linux Foundation 1.1 root hub"
  Hotplug: USB
  Vendor: usb 0x1d6b "Linux Foundation"
  Device: usb 0x0001 "1.1 root hub"
  Revision: "4.12"
  Serial ID: "0000:00:01.2"
  Driver: "hub"
  Driver Modules: "usbcore"
  Speed: 12 Mbps
  Module Alias: "usb:v1D6Bp0001d0412dc09dsc00dp00ic09isc00ip00in00"
  Driver Info #0:
    Driver Status: usbcore is active
    Driver Activation Cmd: "modprobe usbcore"
  Config Status: cfg=new, avail=yes, need=no, active=unknown

03: USB 00.0: 10503 USB Mouse
  [Created at usb.122]
  Unique ID: ADDn.ej3IqYN_t83
  Parent ID: k4bc.lBczeyMQyT5
  SysFS ID: /devices/pci0000:00/0000:00:01.2/usb1/1-1/1-1:1.0
  SysFS BusID: 1-1:1.0
  Hardware Class: mouse
  Model: "Adomax QEMU USB Tablet"
  Hotplug: USB
  Vendor: usb 0x0627 "Adomax Technology Co., Ltd"
  Device: usb 0x0001 "QEMU USB Tablet"
  Serial ID: "42"
  Compatible to: int 0x0210 0x0013
  Driver: "usbhid"
  Driver Modules: "usbhid"
  Device File: /dev/input/mice (/dev/input/mouse2)
  Device Files: /dev/input/mice, /dev/input/mouse2, /dev/input/event4, /dev/input/js0, /dev/input/by-id/usb-QEMU_QEMU_USB_Tablet_42-event-mouse, /dev/input/by-
path/pci-0000:00:01.2-usb-0:1:1.0-event-mouse, /dev/input/by-id/usb-QEMU_QEMU_USB_Tablet_42-mouse, /dev/input/by-path/pci-0000:00:01.2-usb-0:1:1.0-mouse
  Device Number: char 13:63 (char 13:34)
  Speed: 12 Mbps
  Module Alias: "usb:v0627p0001d0000dc00dsc00dp00ic03isc00ip02in00"
  Driver Info #0:
    Buttons: 3
    Wheels: 1
    XFree86 Protocol: explorerps/2
    GPM Protocol: exps2
  Config Status: cfg=new, avail=yes, need=no, active=unknown
  Attached to: #2 (Hub)

Display Memory Information

To display detailed detailed memory information, use --memory option with hwinfo command.

$ hwinfo --memory
01: None 00.0: 10102 Main Memory
  [Created at memory.74]
  Unique ID: rdCR.CxwsZFjVASF
  Hardware Class: memory
  Model: "Main Memory"
  Memory Range: 0x00000000-0x7a4abfff (rw)
  Memory Size: 1 GB + 896 MB
  Config Status: cfg=new, avail=yes, need=no, active=unknown

Display PCI Device Controller

To display detailed pci device information, use --pci option with hwinfo command.

$ hwinfo --pci
07: PCI 00.0: 0600 Host bridge
  [Created at pci.378]
  Unique ID: qLht.YeL3TKDjrxE
  SysFS ID: /devices/pci0000:00/0000:00:00.0
  SysFS BusID: 0000:00:00.0
  Hardware Class: bridge
  Model: "Red Hat Qemu virtual machine"
  Vendor: pci 0x8086 "Intel Corporation"
  Device: pci 0x1237 "440FX - 82441FX PMC [Natoma]"
  SubVendor: pci 0x1af4 "Red Hat, Inc"
  SubDevice: pci 0x1100 "Qemu virtual machine"
  Revision: 0x02
  Module Alias: "pci:v00008086d00001237sv00001AF4sd00001100bc06sc00i00"
  Driver Info #0:
    Driver Status: intel_agp is active
    Driver Activation Cmd: "modprobe intel_agp"
  Config Status: cfg=new, avail=yes, need=no, active=unknown

09: PCI 03.0: 0200 Ethernet controller
  [Created at pci.378]
  Unique ID: 3hqH.pkM7KXDR457
  SysFS ID: /devices/pci0000:00/0000:00:03.0
  SysFS BusID: 0000:00:03.0
  Hardware Class: unknown
  Model: "Red Hat Virtio network device"
  Vendor: pci 0x1af4 "Red Hat, Inc"
  Device: pci 0x1000 "Virtio network device"
  SubVendor: pci 0x1af4 "Red Hat, Inc"
  SubDevice: pci 0x0001
  Driver: "virtio-pci"
  Driver Modules: "virtio_pci"
  I/O Ports: 0xc060-0xc07f (rw)
  Memory Range: 0xfebd1000-0xfebd1fff (rw,non-prefetchable)
  Memory Range: 0xfeb80000-0xfebbffff (ro,non-prefetchable,disabled)
  IRQ: 10 (73078 events)
  Module Alias: "pci:v00001AF4d00001000sv00001AF4sd00000001bc02sc00i00"
  Driver Info #0:
    Driver Status: virtio_pci is active
    Driver Activation Cmd: "modprobe virtio_pci"
  Config Status: cfg=new, avail=yes, need=no, active=unknown

Log Output into file

hwinfo offering log option which used to store hwinfo output into file for later analyze.

$ hwinfo --log hwinfo.txt
or
$ hwinfo --cpu --log hwinfo.txt

Hwinfo Man Page

To know more about hwinfo, navigate to help section or man page.

$ man hwinfo
or
$ hwinfo --help

You may also like...

Close
Please support the site
By clicking any of these buttons you help our site to get better