Linux Detecting: Second CPU / Processor

ht‮:spt‬//www.lautturi.com
Linux Detecting: Second CPU / Processor

To check if a Linux system has more than one CPU or processor, you can use the lscpu command. This utility displays detailed information about the system's CPU architecture, including the number of processors, the number of cores per processor, and the number of threads per core.

To use lscpu, simply run the command without any arguments:

lscpu

This will display a summary of the system's CPU architecture, including the number of processors. Look for the line that says "CPU(s):" followed by a number. This number indicates the total number of processors in the system. If the number is greater than 1, it means that the system has more than one processor.

Here's an example of the output of the lscpu command on a system with two processors:

CPU(s):                2

In addition to displaying the number of processors, lscpu also provides a lot of other information about the CPU architecture. For example, it will show the type of CPU, the number of cores per processor, and the number of threads per core.

Created Time:2017-10-29 22:08:53  Author:lautturi