↑ ↓ select, Enter open, Esc close

Show CPU model, cores and threads

user@server
LC_ALL=C lscpu | grep -E '^\s*(Model name|CPU\(s\)|Thread\(s\) per core|Core\(s\) per socket|Socket\(s\)|Virtualization|Hypervisor vendor|L3)'

Filters the most important lines from the output of lscpu. CPU(s) is the number of logical processors, that is, sockets times cores times threads per core. On virtual servers, Hypervisor vendor appears and the values refer to the vCPUs. LC_ALL=C ensures English field names, so the filter also works on systems set to another language.

Note: lscpu without the filter gives the full output including CPU flags.

Also searched as

  • which processor is installed
  • how many cpu cores does the server have
  • show cpu model linux

Related one-liners

All in System and hardware

Read first, then run.

The commands on myline.de act directly on servers, files and databases. A wrong path or placeholder can delete data irreversibly or make a server unreachable.

  • All commands are provided without warranty and are not tested on every system.
  • Understand what a command does before running it, and check every placeholder.
  • Make a backup first and, if possible, try it on a test system.
  • You run commands at your own risk. Liability for damages is excluded to the extent permitted by law.