Re: [CentOS-virt] How many virtual guest 'cpus' can a core duo 'quad' core support

2012-02-24 Thread Todd And Margo Chester
On 02/23/2012 11:23 AM, James B. Byrne wrote:
>
> On Wed, February 22, 2012 12:25, Todd And Margo Chester
>>
>> Therefore, in your given case, think six not twelve.
>> Common advice is
>> to leave
>> one core for the host OS/scheduler.  Which leaves you with
>> 5 physical
>> CPUs to
>> allocate.
>>
>
>
> Thank you.  I never planned to allocate to any guest more
> cpus that were physically available.  What I was checking
> was that a single physical cpu with four cores actually
> counted as four cpus insofar as kvm itself was concerned.
> I have allocated guests their processors on the basis that
> 1 core = 1 cpu.  But it occurred to me that core might
> actually mean something different and so I wanted to
> verify my understanding.

You are welcome.  It took me forever to get a straight
answer on this issue (~3 years).  I am glad I could
share it with you.

-T
___
CentOS-virt mailing list
CentOS-virt@centos.org
http://lists.centos.org/mailman/listinfo/centos-virt


Re: [CentOS-virt] How many virtual guest 'cpus' can a core duo 'quad' core support

2012-02-23 Thread James B. Byrne

On Wed, February 22, 2012 12:25, Todd And Margo Chester
>
> Therefore, in your given case, think six not twelve.
> Common advice is
> to leave
> one core for the host OS/scheduler.  Which leaves you with
> 5 physical
> CPUs to
> allocate.
>


Thank you.  I never planned to allocate to any guest more
cpus that were physically available.  What I was checking
was that a single physical cpu with four cores actually
counted as four cpus insofar as kvm itself was concerned. 
I have allocated guests their processors on the basis that
1 core = 1 cpu.  But it occurred to me that core might
actually mean something different and so I wanted to
verify my understanding.




-- 
***  E-Mail is NOT a SECURE channel  ***
James B. Byrnemailto:byrn...@harte-lyne.ca
Harte & Lyne Limited  http://www.harte-lyne.ca
9 Brockley Drive  vox: +1 905 561 1241
Hamilton, Ontario fax: +1 905 561 0757
Canada  L8E 3C3

___
CentOS-virt mailing list
CentOS-virt@centos.org
http://lists.centos.org/mailman/listinfo/centos-virt


Re: [CentOS-virt] How many virtual guest 'cpus' can a core duo 'quad' core support

2012-02-22 Thread Todd And Margo Chester
On 02/21/2012 12:59 PM, James B. Byrne wrote:
> CentOS-6.2
>
> What is the maximum number of cpus can I configure for a
> single vm guest running on a host with this hardware?
>
> # lscpu
> Architecture:  x86_64
> CPU op-mode(s):32-bit, 64-bit
> Byte Order:Little Endian
> CPU(s):4
> On-line CPU(s) list:   0-3
> Thread(s) per core:1
> Core(s) per socket:4
> CPU socket(s): 1
> NUMA node(s):  1
> Vendor ID: GenuineIntel
> CPU family:6
> Model: 23
> Stepping:  10
> CPU MHz:   1998.000
> BogoMIPS:  5331.76
> Virtualization:VT-x
> L1d cache: 32K
> L1i cache: 32K
> L2 cache:  2048K
> NUMA node0 CPU(s): 0-3
>
> I ask this because it occurs to me that I may have missed
> something fundamental respecting the use of the initialism
> CPU vice the term Cores.
>
>

Hi James,

I had a dialog with the KVM developers on the subject.  The answer
is as many as you wish, although performance will suffer if you
assign 100 vcpu to a four core machine.  Here is my notes on the
dialog.

-T


KVM Cores and Hyperthreading explained:

CentOS-virt mailing list:

 > Do you have a rule of thumb as to how many core to assign
 > > to a guest?  For instance, with an Intel x5650 with 6 real
 > > and 12 hyperthreaded cores, how many cores would you assign
 > > to the guest?


___

It fully depends on the load of your guests and how many guests you
want/need to run on a single server.

You need to perform some testing to know what will work the best in
your case. One thing to remember though: In your case, if you create
two guests with 12 virtual CPUs each, and one of them crashes and take
all its 12 virtual CPUs up to 100%, it will essentially take most of
the processing power away from the second guest, leaving the second
guest in a close-to-useless state (depending on your scheduler, but
you get the point). If you on the other hand had assigned 6 cores to
each of them, the second guest would have remained unaffected, since
it just uses the 6 cores with no load. So if your guest will not
utilize the extra CPUs anyway, then don't assign them.

Best regards
Kenni
___



It also depends on what each guest is doing.  Some software, like the
Postfix MTA, has issues with the timer in a VM and in circumstances
like that you want to minimise the number of cores if you can't skip
the use of the VM entirely.

Kenni is right, though, test it and see whatever works best for your
project.

Regards,
Ben
___



You may already know this, but don't rely on hyperthreading giving you 
very much
extra.  At best it's squeezing some useful work out of what would be a 
few idle
cycles waiting for the instruction pipeline to re-fill.  At worst it 
degrades
performance and has been known to be a security hazard.

Therefore, in your given case, think six not twelve.  Common advice is 
to leave
one core for the host OS/scheduler.  Which leaves you with 5 physical 
CPUs to
allocate.

N


___
It's how it works, think of kvm as an application. If you tell that it
should use 4 core it's like if you tell it to use 4 processes or
threads. The host operating system will decide which processor core or
thread to use ...

Cheers,
G

___
CentOS-virt mailing list
CentOS-virt@centos.org
http://lists.centos.org/mailman/listinfo/centos-virt


Re: [CentOS-virt] How many virtual guest 'cpus' can a core duo 'quad' core support

2012-02-22 Thread Alexander Dalloz
Am 22.02.2012 08:46, schrieb Andreas Reschke:
>> The maximum you can assign to a single VM is the amount of CPUs
>> > visible to the KVM host.  So a quad core is shows as 4 CPUs to the OS,
>> > so you could assign 4 vCPUs to a guest.  To see how much is available
>> > and seen by KVM run # virsh nodeinfo.
>> > 
>> >  - Trey

> Hello,
> 
> I think thats not correct. I my case I have a HP N36L Server with one 
> Dualcore Prozessor and 4 guest running. You can overbook the prozessor.
> Maybe the performance goes down.
>  
>  
> Gruß 
> Andreas Reschke

Andreas,

Trey didn't say anything different.

You can assign at max the number of physical cores of the KVM host to
any VM. So if your KVM host has 4 cores you can have 1 VM with 4 vCPUs.
And another VM with 4 vCPUs as well. Then you are overbooked.

Alexander
___
CentOS-virt mailing list
CentOS-virt@centos.org
http://lists.centos.org/mailman/listinfo/centos-virt


Re: [CentOS-virt] How many virtual guest 'cpus' can a core duo 'quad' core support

2012-02-21 Thread Trey Dockendorf
On Tue, Feb 21, 2012 at 2:59 PM, James B. Byrne  wrote:
> CentOS-6.2
>
> What is the maximum number of cpus can I configure for a
> single vm guest running on a host with this hardware?
>
> # lscpu
> Architecture:          x86_64
> CPU op-mode(s):        32-bit, 64-bit
> Byte Order:            Little Endian
> CPU(s):                4
> On-line CPU(s) list:   0-3
> Thread(s) per core:    1
> Core(s) per socket:    4
> CPU socket(s):         1
> NUMA node(s):          1
> Vendor ID:             GenuineIntel
> CPU family:            6
> Model:                 23
> Stepping:              10
> CPU MHz:               1998.000
> BogoMIPS:              5331.76
> Virtualization:        VT-x
> L1d cache:             32K
> L1i cache:             32K
> L2 cache:              2048K
> NUMA node0 CPU(s):     0-3
>
> I ask this because it occurs to me that I may have missed
> something fundamental respecting the use of the initialism
> CPU vice the term Cores.
>
>
> --
> ***          E-Mail is NOT a SECURE channel          ***
> James B. Byrne                mailto:byrn...@harte-lyne.ca
> Harte & Lyne Limited          http://www.harte-lyne.ca
> 9 Brockley Drive              vox: +1 905 561 1241
> Hamilton, Ontario             fax: +1 905 561 0757
> Canada  L8E 3C3
>
> ___
> CentOS-virt mailing list
> CentOS-virt@centos.org
> http://lists.centos.org/mailman/listinfo/centos-virt


The maximum you can assign to a single VM is the amount of CPUs
visible to the KVM host.  So a quad core is shows as 4 CPUs to the OS,
so you could assign 4 vCPUs to a guest.  To see how much is available
and seen by KVM run # virsh nodeinfo.

 - Trey
___
CentOS-virt mailing list
CentOS-virt@centos.org
http://lists.centos.org/mailman/listinfo/centos-virt


[CentOS-virt] How many virtual guest 'cpus' can a core duo 'quad' core support

2012-02-21 Thread James B. Byrne
CentOS-6.2

What is the maximum number of cpus can I configure for a
single vm guest running on a host with this hardware?

# lscpu
Architecture:  x86_64
CPU op-mode(s):32-bit, 64-bit
Byte Order:Little Endian
CPU(s):4
On-line CPU(s) list:   0-3
Thread(s) per core:1
Core(s) per socket:4
CPU socket(s): 1
NUMA node(s):  1
Vendor ID: GenuineIntel
CPU family:6
Model: 23
Stepping:  10
CPU MHz:   1998.000
BogoMIPS:  5331.76
Virtualization:VT-x
L1d cache: 32K
L1i cache: 32K
L2 cache:  2048K
NUMA node0 CPU(s): 0-3

I ask this because it occurs to me that I may have missed
something fundamental respecting the use of the initialism
CPU vice the term Cores.


-- 
***  E-Mail is NOT a SECURE channel  ***
James B. Byrnemailto:byrn...@harte-lyne.ca
Harte & Lyne Limited  http://www.harte-lyne.ca
9 Brockley Drive  vox: +1 905 561 1241
Hamilton, Ontario fax: +1 905 561 0757
Canada  L8E 3C3

___
CentOS-virt mailing list
CentOS-virt@centos.org
http://lists.centos.org/mailman/listinfo/centos-virt