5

can any one please clarify the difference between actual no of processors and CPU cores. in my case i am having Intel Xeon® Processor E5620 as per intels product page: its having

# of Cores 4 

# of Threads 8

and cat /proc/cpuinfo |grep processor|wc -l is showing 16 so what is this 16 showing here?. I am planning to virtualize this machine with xen to 4 vms,each with 4 cpu.So it will be better if i can understand about these values and assigning vcpus to guest vm.

keeth
  • 53
  • 3

1 Answers1

5

An E5620 CPU has 4 cores on the die. With Hyper-Threading turned on, that gives you 8 threads.

Perhaps your machine has 2 physical E5620 CPUs? If it's not powered on, try opening the case and counting them.

If it's powered up and you can log in, try this: cat /proc/cpuinfo | grep “physical id” | sort | uniq | wc -l

2 physical CPUs x 4 cores/CPU x 2 hyper-threads/core = 16 threads

Magellan
  • 4,431
  • 3
  • 29
  • 53
  • Is there a way to check Physical CPU with out opening..i dont have access to machine physically. – keeth Oct 03 '12 at 06:46
  • You were already pretty close in your question. See edit above. – Magellan Oct 03 '12 at 07:01
  • 1) Checking for physical CPUs: You can check the boot logs for multiple CPU (dmesg, or /var.run/dmesg.boot). Or you could check in the BIOS (assuming your remote access card lets you do that without physical access. 2) You did not ask this, but you do not need to match the number of virtual CPU with the physical CPUs or treads. E.g. you could give 4 VM each 8 CPUs and it would just work. (Or a variation on that). – Hennes Oct 03 '12 at 14:18
  • @Hennes: I have a preference for using proc for that stuff. Sometimes less inscrutable than digging through 1000+ lines of dmesg log. – Magellan Oct 03 '12 at 14:39