*Glossary*
*noun* | *meaning* |
---|---|
CPU physical number | The number of CPUs actually inserted on the motherboard |
Number of CPU cores | The number of chipsets that can process data on a single CPU, such as dual-core, quad-core, etc. (cpu cores) |
Number of logical CPUs/number of threads | Under normal circumstances, logical cpu=number of physical CPUs×number of cores. If they are not equal, it means that the CPU of the server supports hyper-threading technology. |
*View the physical number of CPUs*
grep ‘physical id’ /proc/cpuinfo | sort -u | wc -l
*View the number of CPU cores* grep'core id' /proc/cpuinfo | sort -u | wc -l
*View the number of CPU threads*
#Logic cpu number: Under normal circumstances, logical cpu = physical CPU number × each core number, if not equal, it means that the server's CPU supports hyper-threading technology (HT: in simple terms, it can make processing # in the device The 1 core of the OS plays a role in the operating system like 2 cores. In this way, the execution resources available to the operating system are doubled, and the overall performance of the system is greatly improved. Number × number of each core x2)
cat /proc/cpuinfo| grep “processor”|wc -l4
grep 'processor' / proc / cpuinfo | sort -u | wc -l4
*View CPU model*
cat /proc/cpuinfo | grep name | sort | uniq
dmidecode -s processor-version | uniq #Use uniq for deduplication
*View the detailed information of the CPU*
#CPU has several cores, it will output several repeated information
cat /proc/cpuinfo
*View the detailed information of the CPU*
lscpu
*CPU configuration summary*
Through the above query, we can know that the server is a 4-core CPU with 1 channel, the CPU model is Intel® Core™ i7-8550U CPU @ 1.80GHz, and the CPU does not have hyperthreading.