lscpu
Linux · System · reference only
What it does
Shows CPU information: architecture, model, number of cores and threads, frequencies and caches.
Syntax
lscpu [opciones]
Options and parameters
-eShows a table with one row per logical CPU.
-pShows the information in a format easy for programs to process.
-JShows the information as JSON.
-CShows CPU cache information.
-aIncludes both online and offline CPUs in the table.
-bShows only the CPUs that are online.
Usage examples
lscpuShows the full CPU summary.
lscpu -eLists each logical CPU with its core and state.
lscpu -JGets the same data as JSON to use in a script.
lscpu | grep -i modelFilters the lines that mention the processor model.
Notes and common mistakes
- It is part of util-linux and reads its information from /proc/cpuinfo and /sys.