Re: VirtualBox multi cpu

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Yes, indeed....

I've modified the number of cpus via the command line :

VBoxManage modifyvm MyVM --cpus x

 From 3 cpus, the performances go down... But I don't really understand 
why... If someone can give me ways of explanations...

Le 22/03/11 20:52, Kevin Martin a écrit :
>
> On 03/22/2011 01:00 PM, Christopher A. Williams wrote:
>> On Tue, 2011-03-22 at 12:25 -0500, Kevin Martin wrote:
>>> On 03/22/2011 12:11 PM, Patrick Bartek wrote:
>>>> --- On Tue, 3/22/11, Luc MAIGNAN<luc.maignan@xxxxxxxxxxxx>  wrote:
>>>>
>>>>> I use VirtualBox on a RHEL5 with 24 cores (6 x4-cores
>>>>> processors).
>>>>> But it seems like only one or two processors are used. How
>>>>> can I
>>>>> configure VirtualBox and/or my virtual machine to allow it
>>>>> to use all
>>>>> processors ?
>>>> Does this not work:  Start the VirtualBox interface, choose the virtual machine you want to work on, but don't start it; click on System in the Details list, choose Processor, set Processor(s) slider up to the number of virtual CPUs you want to use.
>>>>
>>>> > From the VirtualBox v. 3.1.6 manual:
>>>>
>>>>
>>>> 3.4.2 “Processor†tab
>>>>
>>>>     On the “Processor†tab, you can set how many virtual CPU cores the guest operating systems should see. Starting with version 3.0, VirtualBox supports symmetrical multi-processing (SMP) and can present up to 32 virtual CPU cores to each virtual machine.
>>>>    You should not, however, configure virtual machines to use more CPU cores than you have available physically.
>>>>
>>>>
>>>>
>>>> B
>>> It sounds as if the host is not allocating VM's to more than a few CPU's. Adding additional CPU's in the VB screen may or may not
>>> cause the host O.S. to work as planned. It may just allocate more VM virtual CPU's to the same physical CPU's. I'm thinking that
>>> there's a bug in the host O.S. kernel that's not allocating the VM's to all of the CPU's correctly. So "taskset" may be the only
>>> answer until he can get on a newer kernel.
>> ...Ummm no, that's not how this works.
>>
>> In reality, allocating more virtual CPUs (aka a vCPU or virtual
>> processor) to a VM - be it VirtualBox, VMware, Hyper-V, etc., actually
>> does a have a direct correlation to the number of CPU cores that are
>> used by that VM on the physical host. The more vCPUs, the more physical
>> cores are allocated to the VM by the system scheduler foa given set of
>> CPU cycles (be that the hypervisor, the host OS, or both as
>> appropriate). That's also why you shouldn't (actually can't) allocate
>> more vCPUs than the lesser of either the number of CPU cores on the host
>> system or the total number that the hypervisor will support (32 in the
>> case of vBox).
>>
>> Be careful when doing multi-vCPU VMs though. Adding more does not
>> necessarily mean you will get a boost in performance of either the VM or
>> the host system. In fact, there are cases where this can actually cause
>> a performance decrease. Make sure you know that the VM will use the
>> number of cores (vCPUs) you are wanting to allocate.
>>
>> This is also something that must be pre-allocated in vBox. Thus, the
>> correct procedure is to add virtual CPUs via the "Processor" tab as
>> described above. Other hypervisors (VMware vSphere, Hyper-V) are
>> starting to support "hot add" of vCPUs on Windows and Linux VMs. None,
>> however, support a "hot remove" of vCPUs at this time.
>>
>> Cheers,
>>
>> Chris
>> (VMware Certified Advanced Professional - Datacenter Design)
>>
> But that's not what the OP said. He said that the machine had 24 cores and the the VM's were being allocated to only a cpu or two.
> It sounds like the OP has multiple VM's with multi virtual cpu's per VM setup and that either the virtual machine manager on the
> host wasn't allocating the virtual cpu's around correctly or that the kernel is not allocating them correctly. He doesn't mention
> which version of VirtualBox (he's not using VMWare) he's using, nor does he mention if he's tried to allocate more virtual cpu's
> than would fit on 2 physical cpu's. It's possible that he just doesn't have enough virtual cpu's allocated to need more than 2
> physical cpu's in use.
>
> K

-- 
users mailing list
users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines



[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux