guest@linuxthings:~/guides$ man hardware
Hardware & System Info
Commands to display Linux system information and hardware details.
System Information
uname -a # Show system and kernel info
uname -r # Kernel release only
uname -m # Hardware architecture, e.g. x86_64 or aarch64
hostname # Show system hostname
hostnamectl # Hostname, OS, kernel and hardware summary
who -b # Show last boot time
uptime -p # How long the system has been up
cat /etc/os-release # Show operating system version info
lsb_release -a # Distribution details (Debian/Ubuntu family)Hardware Resources
lscpu # CPU architecture information
nproc # Number of available CPU cores
lsblk # List block devices (storage)
lsusb # List USB devices
lspci # List PCI devices
lspci -v # ...with more detail (use sudo for everything)
lspci -k # ...and the kernel driver for each device
free -h # Show free and used memoryIn free output, the available column is the best estimate of memory you can still use. The kernel borrows idle RAM as disk cache (buff/cache) and hands it back when programs need it, so a low free figure is normal.
Detailed Inventory
sudo lshw -short # One line per device: CPU, memory, disks, network
sudo lshw -class network # Just one class of hardware
sudo lshw -html > hw.html # Full report as a web page
hwinfo --short # Alternative hardware lister (if installed)
sudo dmidecode -t memory # Memory slots and modules from the firmware tables
sudo dmidecode -t system # Manufacturer, model and serial numberKernel Messages and Drivers
sudo dmesg | less # Kernel ring buffer: device detection, driver errors
sudo dmesg -w # Follow new kernel messages (plug in a USB device to see it)
lsmod # Loaded kernel modules (drivers)
modinfo usb_storage # Details about one moduleSensors and Live Activity
sudo sensors-detect # One-time setup for lm-sensors
sensors # CPU temperatures, fan speeds, voltages
vmstat 2 # Memory, CPU and I/O every 2 seconds
iostat -xz 2 # Per-disk I/O statistics (sysstat package)Some of these tools (lshw, hwinfo, lm-sensors, sysstat) are separate packages that may need installing first.