通过lscpu命令,可以看到CPU的一些基本信息。如下所示,可以很清楚的看到这台服务器使用两个物理socket,每个socket上有6个core,每个core上有两个线程(超线程),所以一共有2 * 6 * 2 = 24个逻辑CPU。

Architecture: x86_64

CPU op-mode(s): 32-bit, 64-bit

Byte Order: Little Endian

CPU(s): 24

On-line CPU(s) list: 0-23

Thread(s) per core: 2

Core(s) per socket: 6

CPU socket(s): 2

NUMA node(s): 2

Vendor ID: GenuineIntel

CPU family: 6

Model: 62

Stepping: 4

CPU MHz: 2601.000

BogoMIPS: 5187.39

Virtualization: VT-x

L1d cache: 32K

L1i cache: 32K

L2 cache: 256K

L3 cache: 15360K

NUMA node0 CPU(s): 0-5,12-17

NUMA node1 CPU(s): 6-11,18-23

通过cat /proc/cpuinfo同样可以看到一些信息,这里会给socket、core和线程设置id。

同一个socket的physical id相同

cpu cores表示此socket上的core数量

如果cpu cores = siblings,表明没有开启超线程

如果cpu cores = 2 * siblings,表明开启了超线程

相同的physical id,相同的core id,但是不同的processor id,表明是同一个core上的逻辑CPU(超线程)

cpuinfo示例如下所示(原文引用已经找不到了,直接贴在这里)

Example 1: Single processor, 1 core, no Hyperthreading

Processor : 0

model name : AMD Duron(tm) processor

cache size : 64 KB

Example 2: Single processor, 1 core, Hyperthreading is enabled.

Notice how we have 2 siblings, but only 1 core. The physical CPU id is the same for both: 0.

processor : 0

model name : Intel(R) Pentium(R) 4 CPU 2.80GHz

cache size : 1024 KB

physical id : 0 # same physical id

siblings : 2

core id : 0 # same core id

cpu cores : 1

processor : 1

model name : Intel(R) Pentium(R) 4 CPU 2.80GHz

cache size : 1024 KB

physical id : 0 # same physical id

siblings : 2

core id : 0 # same core id

cpu cores : 1

Example 3. Single socket Quad Core

Notice how each processor has its own core id. The number of siblings matches the number of cores so there are no Hyperthreading siblings. Also notice the huge L2 cache - 6 MB. That makes sense though, when considering 4 cores share that L2 cache.

processor : 0

model name : Intel(R) Xeon(R) CPU E5410 @ 2.33GHz

cache size : 6144 KB

physical id : 0 # same physical id

siblings : 4

core id : 0 # different core id

cpu cores : 4

processor : 1

model name : Intel(R) Xeon(R) CPU E5410 @ 2.33GHz

cache size : 6144 KB

physical id : 0 # same physical id

siblings : 4

core id : 1 # different core id

cpu cores : 4

processor : 2

model name : Intel(R) Xeon(R) CPU E5410 @ 2.33GHz

cache size : 6144 KB

physical id : 0 # same physical id

siblings : 4

core id : 2 # different core id

cpu cores : 4

processor : 3

model name : Intel(R) Xeon(R) CPU E5410 @ 2.33GHz

cache size : 6144 KB

physical id : 0 # same physical id

siblings : 4

core id : 3 # different core id

cpu cores : 4

Example 3a. Single socket Dual Core

Again, each processor has its own core so this is a dual core system.

processor : 0

model name : Intel(R) Pentium(R) D CPU 3.00GHz

cache size : 2048 KB

physical id : 0 # same physical id

siblings : 2

core id : 0 # different core id

cpu cores : 2

processor : 1

model name : Intel(R) Pentium(R) D CPU 3.00GHz

cache size : 2048 KB

physical id : 0 # same physical id

siblings : 2

core id : 1 # different core id

cpu cores : 2

Example 4. Dual Single core CPU, Hyperthreading ENABLED

This example shows that processer 0 and 2 share the same physical CPU and 1 and 3 share the same physical CPU. The number of siblings is twice the number of cores, which is another clue that this is a system with hyperthreading enabled.

processor : 0

model name : Intel(R) Xeon(TM) CPU 3.60GHz

cache size : 1024 KB

physical id : 0 # different physical id

siblings : 2

core id : 0 # same core id

cpu cores : 1

processor : 1

model name : Intel(R) Xeon(TM) CPU 3.60GHz

cache size : 1024 KB

physical id : 3 # different physical id

siblings : 2

core id : 0 # same core id

cpu cores : 1

processor : 2

model name : Intel(R) Xeon(TM) CPU 3.60GHz

cache size : 1024 KB

physical id : 0 # different physical id

siblings : 2

core id : 0 # same core id

cpu cores : 1

processor : 3

model name : Intel(R) Xeon(TM) CPU 3.60GHz

cache size : 1024 KB

physical id : 3 # different physical id

siblings : 2

core id : 0 # same core id

cpu cores : 1

Example 5. Dual CPU Dual Core No hyperthreading

Of the 5 examples this should be the most capable system processor-wise. There are a total of 4 cores : 2 cores in 2 separate socketed physical CPUs. Each core shares the 4MB cache with its sibling core. The higher clock rate (3.0 GHz vs 2.3GHz) should offer slightly better

performance than example 3.

processor : 0

model name : Intel(R) Xeon(R) CPU 5160 @ 3.00GHz

cache size : 4096 KB

physical id : 0 # different physical id

siblings : 2

core id : 0 # different core id

cpu cores : 2

processor : 1

model name : Intel(R) Xeon(R) CPU 5160 @ 3.00GHz

cache size : 4096 KB

physical id : 0 # different physical id

siblings : 2

core id : 1 # different core id

cpu cores : 2

processor : 2

model name : Intel(R) Xeon(R) CPU 5160 @ 3.00GHz

cache size : 4096 KB

physical id : 3 # different physical id

siblings : 2

core id : 0 # different core id

cpu cores : 2

processor : 3

model name : Intel(R) Xeon(R) CPU 5160 @ 3.00GHz

cache size : 4096 KB

physical id : 3 # different physical id

siblings : 2

core id : 1 # different core id

cpu cores : 2

linux的cpu信息怎么理解,理解Linux下的CPU信息:lscpu cpuinfo相关推荐

  1. linux怎么让cpu不自动降频,Win10 CPU自动降频怎么办?Win10下让CPU不降频设置方法

    有一些用户反馈在Win10系统下CPU会自动降频,也就是自动降低频率以减少资源消耗,如果是平时还没有什么,但是如果你在玩游戏,那么降频给大家带来游戏性能的降低是不能接受的,游戏会变的卡顿下面小编给大家 ...

  2. cpu温度过高 ubuntu_Ubuntu环境下检查CPU 的温度

    原标题:Ubuntu环境下检查CPU 的温度 夏天到了,笔记本过热是最近一个常见的问题.监控硬件温度或许可以帮助你诊断笔记本为什么会过热.本篇中,我们会了解如何在Ubuntu中检查CPU的温度. 我们 ...

  3. cpu温度过高 ubuntu_Ubuntu环境下检查CPU的温度

    夏天到了,笔记本过热是最近一个常见的问题.监控硬件温度或许可以帮助你诊断笔记本为什么会过热.本篇中,我们会了解如何在Ubuntu中检查CPU的温度. 我们将使用一个GUI工具Psensor,它允许你在 ...

  4. linux cpu load 详解,理解linux cpu load - 什么时候应该担心了

    load average: 0.09, 0.05, 0.01 1 大多数人对这些数都有一个模糊的概念:三个数分别代表了一个随着更长时间上的一个平均值(1分钟, 5分钟, 15分钟). 并且值越小越好. ...

  5. linux container容器技术框架性理解

    我对container原理的一些理解(基于linux kernel 2.6.38) by kin 2011.04.17 ======================================== ...

  6. linux下查看CPU、内存、磁盘信息

    1.查看CPU信息 总核数 = 物理CPU个数 X 每颗物理CPU的核数 总逻辑CPU数 = 物理CPU个数 X 每颗物理CPU的核数 X 超线程数 查看物理CPU个数 cat /proc/cpuin ...

  7. Linux下查看CPU信息[/proc/cpuinfo]

    最近在研究linux系统负载的时候,接触到一些关于CPU信息查看的知识,和大家分享一下.通过对/proc/cpuinfo文件中的参数的分析,也学到了不少东西. 在linux操作系统中,CPU的信息在启 ...

  8. linux ps -ef和ps -aux,关于Linux中ps -aux的深入理解

    要想把每一件事情都做到无懈可击,就必须从小事做起,付出你的热情和努力! 直接进入主题: 对于ps -aux的认识 ps -aux:显示所有包含其他使用者的进程 在终端软件输入该命令显示结果如下: ps ...

  9. Linux基础认识 理解GNU/Linux

    "UNIX 是简单的,你不需要成为天才也能理解这种简单" CkJI ?-   -:<N=u;"Ry   由于GNU/Linux这个词太长,下面如果没有特别指明,&q ...

最新文章

  1. 8000字 | 32 张图 | 一文搞懂事务+隔离级别+阻塞+死锁
  2. Saltstack自动化环境部署
  3. java元空间扩容_JVM元空间(Metaspace)
  4. put the eye care sticker on the neck is relief
  5. vue实现多行数据提交_2020年大厂面试指南 Vue篇
  6. 连载:阿里巴巴大数据实践—数据开发平台
  7. C++编程思想:继承与虚函数以及多态
  8. Kafka集群部署CentOS 7
  9. 高职院校计算机基础课程,高职院校计算机基础课程教学探讨的论文
  10. Android Fragment (一)
  11. java in list,Java 8流过滤:IN子句
  12. 快速排序QuickSort
  13. java webservice 入门教程_WebService入门实例教程
  14. 大数据的一些入门教程
  15. EMC EMI EMS 介绍
  16. 网络管理-Pageadmin CMS构建企业网站的方法
  17. BLE MESH中的Secure Network beacon包
  18. Cisco路由器入侵
  19. 天下英雄出我辈 一入江湖岁月催 《江湖行》
  20. 手动清除网卡IP地址的方法

热门文章

  1. 【VOC格式xml文件解析】——Python
  2. c语言结构体编程,[编程] C语言的结构体详解
  3. 分享:一款快速传输大文件、支持英文版的工具
  4. 百度正式发布PaddlePaddle深度强化学习框架PARL
  5. setTimeout详解
  6. 2017.10.13java上机出现中的问题
  7. 命令行分析java线程CPU占用
  8. LeetCode OJ - Populating Next Right Pointers in Each Node II
  9. 深入理解Java内存模型(七)——总结
  10. Android service 小研究