作者:范军 (Frank Fan) 新浪微博:@frankfan7
虚拟机需要多少个vCPU呢?是不是个数越多性能越好呢?这方面存在着很多误区。给VM配置CPU资源的时候,要精打细算才能最大可能的利用已有资源,来满足商业应用的需要。有的情况下为某个VM设置过多vCPU数目,反而会造成该应能的性能下降。也造成整个系统的资源浪费。
本文从概念到实战来阐述如何做好虚拟机上CPU资源规划。
一概念:
首先我们明确一些概念。
A CPU socket or a CPUpackage refers to a physical unit of CPU which is plugged into a system board.For example, a 4-way system or a 4-socket system can contain up to four CPUpackages
Core
A CPU socket or a CPUpackage refers to a physical unit of CPU which is plugged into a system board.For example, a 4-way system or a 4-socket system can contain up to four CPUpackages
Logical processor:
Hyperthreadingtechnology allows a single physical processor core to behave like two logical processors.The processor can run two independent applications at the same time. Aprocessor core may have multiple logical processors