← Knowledge Base
LinuxReference note1 min read · updated 2026-11-27

Hardware and system information from the command line

CPU, memory, disks, PCI/USB devices, temperatures and uptime.

hardwarelscpulsblk
uname -a; hostnamectl; uptime
lscpu                     # CPU model, cores, flags
free -h                   # memory and swap
lsblk -f                  # disks, partitions, filesystems, UUIDs
lspci; lsusb              # PCI and USB devices
sudo dmidecode -t system  # vendor, model, serial (needs root)
sudo smartctl -a /dev/sda # disk health (apt install smartmontools)
sensors                   # temperatures (apt install lm-sensors)
ip -br a                  # interfaces and addresses

/proc/cpuinfo and /proc/meminfo are the raw sources. On virtual machines many hardware values are virtualised or empty, which is normal.