This is indeed a bug in the FreeBSD code. It's using the generic implementation of RTMpGetCoreCount() -- which is euqal to the number of cores. Someone with FreeBSD knowledge should provide a fix (our team has no time to actively maintain the FreeBSD sources).klaus wrote:Not todayAt least a Xeon E5-1650 v3 should not be used in anything but a single socket server. The log message is misleading, it's showing the logical CPU count (which includes hyperthreading).
Discuss the 5.1.18 release
-
frank
- Oracle Corporation
- Posts: 3362
- Joined: 7. Jun 2007, 09:11
- Primary OS: Debian Sid
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Linux, Windows
- Location: Dresden, Germany
- Contact:
Re: Discuss the 5.1.18 release
Re: Discuss the 5.1.18 release
frank, could you tell why guest shall not use hyperthreading cores? Only physical ones.
From the manual:
"You should not, however, configure virtual machines to use more CPU cores than you have available physically (real cores, no hyperthreads)"
Thanks
From the manual:
"You should not, however, configure virtual machines to use more CPU cores than you have available physically (real cores, no hyperthreads)"
Thanks
Re: Discuss the 5.1.18 release
Executive summary of "why can't VirtualBox use HT for VMs": it can't control the execution of host OS threads which implement a VCPU to make sure that the overall behavior looks like HT (i.e. there's no way to ask any popular OS out there to schedule 2 host threads on a single host CPU core). The uncontrollable scheduling results in unpredictable performance, usually much worse than without reporting HT and sticking to cores.
-
socratis
- Site Moderator
- Posts: 27329
- Joined: 22. Oct 2010, 11:03
- Primary OS: Mac OS X other
- VBox Version: VirtualBox+Oracle ExtPack
- Guest OSses: Win(*>98), Linux*, OSX>10.5
- Location: Greece
Re: Discuss the 5.1.18 release
Here is another answer that I keep handy and I quote whenever this question comes up. The last couple of sentences are really interesting:Selin wrote:could you tell why guest shall not use hyperthreading cores? Only physical ones.
Ramshankar in a [url=https://forums.virtualbox.org/viewtopic.php?f=1&t=79734#p373129]recent post[/url] wrote:
Why is it a bad idea to allocate as many VCPUs as there are physical CPUs?
You cannot have the best of both worlds. Most modern Intel CPUs have VT-x preemption timers, which VirtualBox has been using for years now. This lets us run chunks of guest code and still get interrupted to run host code depending on how we program the preemption timer. However, the question is not whether we can or cannot interrupt guest code, we normally can. The problem is that there are tasks that require to be run in reasonable frequency & amount of time both on the host *and* the guest. If you starve the host or guest of interrupts or introduce latency because there simply isn't enough compute power available, you will be creating bottlenecks.
Getting in and out of executing guest code via VT-x is still quite an expensive operation. We call it a world-switch or world round-trip, (i.e. VM-entry, execute guest, VM-exit). This is done in ring-0 (kernel) on the host, sometimes (especially on Windows hosts) we are forced to return all the way to ring-3 sometimes in order to satisfy DPC (Deferred Procedure Call) latency. Overall, you're going to have strange latencies introduced in unexpected places if you "overcommit". It is totally possible to run 4 VCPU VM on a 4 CPU host (I do it on my own my Linux dev box sometimes) but it is not something you should be doing if you care about reasonable performance; in extreme cases of overcommitment you may encounter program misbehavior (like when disk requests times out) which the programs are never designed to handle. In the not so severe case you may end up with some strange timeouts but not fatal errors.
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
Re: Discuss the 5.1.18 release
It helpsfrank wrote:I think I know the problem. Could you tryCode: Select all
VBoxManage setextradata VM_NAME VBoxInternal/Devices/acpi/0/Config/PciPref64Enabled 0
Thank you very much!