Can't enable multiple CPU on VirtualBox [closed] - windows

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 2 years ago.
Improve this question
I would like to use more than one CPU to run Ubuntu 14.04 (Trusty Tahr) 32-bit in VirtualBox, but when I stop the machine and go in Settings → System → Processor, the processor(s) slider is grayed out as you can see in the screenshot image. How can I enable this feature?
Host OS: Windows 10 Pro 64-bit
Guest OS: Ubuntu 14.04 32-bit
VirtualBox: Version 5.1.22 r115126
Processor: Intel(R) Core(TM) i7-3770 CPU # 3.40 GHz (8 CPUs), ~3.4 GHz
PS: My problem in the first instance is that the Ubuntu virtual machine is extremely slow and I would like to improve the performance, so any suggestion for that would also be welcome.

To increase performance you need to increase RAM and to use more than one CPU you need to enable "Virtualization technology" in the BIOS.
Go to your BIOS options and search for "Virtualization technology" under "System settings" or similar. This is either called Intel-Vi-D or Intel-Vi with AMD processor. That name is then similar to AMD-V.
If you still have a problem with your VirtualBox not giving you an option to use multiple CPUs then you will most probably have to check if Hyper-V is installed in the "Turn Windows Features on or off". Which you might need to disable in order to use multiple CPU cores.
Some computers still might have no function towards virtualization use of multiple cores. That can be old computer models or more specific laptop computers. In some, you might need to check if there is a new BIOS version available for your computer.

For me I just had to forget the saved state with a right click on the virtual device.

Please make sure that you disable the Hyper-V. Go to Control Panel → Turn Windows features on or off → Uncheck Hyper-V → Restart your computer.

My problem is just a little bit different, but it fits the question. I can not make the guest use more than one processor.
The slider is not grayed, and I can set it to 1..4 (it is a dual core host).
But setting it on 2 and booting the Windows guest, it only sees one.
I had also tried all possible values for the slider. Windows guest always see one, not more.
If on Windows guest, I type set on a console. I always get a line with, no matter the position on the slider:
NUMBER_OF_PROCESSORS=1
I can not enable multiple CPUs on VirtualBox that guest.
The weird thing is that if I put a live CD Linux distribution ISO on that guest's virtual CD unit, it can see all the processors I set on the slider... it is just the Windows guest the one that ignores the slider... I am getting mad... and am out of ideas.
The problem occurs because when Windows was installed it was configured with only one processor, so it installed in a no multi-processor way and there is no way for it to see more than one, except re-intalling Windows, but this time with two or more on the slider, so it installs in SMP mode.
So, for anyone having the problem:
I can not use more than one processor on windows guest
I can move the slider
The answer is not going to the BIOS. The answer is:
Please install that Windows with the slider in 2 or more, not on just 1.
I remember I had a similar problem with an old Windows XP guest. At that time I had tried a patch to change Windows to SMP mode and a reboot, but it was so unstable, that I opted to reinstall it directly with 2 on the slider.

Looks like you have to power off the virtual machine (do not Save state)and edit those settings.

Please stop and power off your VM and then drag.
It will work.

Open Virtual Box.
Click the name of the virtual machine that you want to make your CPU available to, then click the "Settings" button at the top of the window.
Click the "System" heading on the left side of the Settings window.
Click the "Processor" tab at the top of the window.
Drag the slider next to "Processor(s)" to the right until the value matches the number of processors or processor cores installed in your computer.
Drag the slider next to "Execution Cap" to the right until the value reads "100." This allows VirtualBox to use all of your processor's resources.
Click "OK," then double-click the virtual machine to turn it on.

Related

Docker on windows with broken bios

I've wanted to install docker on my windows. I'm getting an error. Hardware assisted virtualization and data execution protection must be enabled in the BIOS. See . I can't go to my bios, after pressing f2 i have just a black screen, i tried to restart my computer manually and from windows in advanced settings from tutorials. In task manager my virtualization is off, I checked my Cpu supports virtualization on Intel Processor Identification Utility and it is. My Cpu is i7 4770k 3,5Ghz. I downloaded bios update for my motherboard but I know, I have to put it on my Pendrive and open it from my bios, couldn't install it straight from my pc with .CAP extension. My motherboard is Asus Z97M-PLUS. I tried to set my virtualization without bios with tutorials, PowerShell commands, changing settings, avast, hyperV. Can't describe exactly what I was doing and which commands I was putting in because I tried everything I found.
It is difficult to help you in this case as this is a very case-specific problem, especially hardware specific. The fact that you can't enter your bios will make enabling virtualization very difficult, as this switch must be switched there, and only there. I suppose you could try resetting your BIOS by shorting two pins / pressing a button on your motherboard, to see if that makes it want to open again.
Try this motherboard manual document at section 1.2.6 and 1.2.7 depending on your use case.
Furthermore, this website probably is not the best place to ask these sort of questions, and tech forums would probably be better able to help you further.

Unable to create the virtual machine

I was so happy today that I have been finally able to install Windows Phone 8 SDK and try it a bit. I installed fresh new installation of Windows 8 Pro into my virtual machine (I am running if from Parallels) and then installed Windows Phone 8 SDK.
Everything went smooth, Visual Studio Express is installed and running, but when I created new project and tried to deploy it, VS fails with really weird message.
First of all, message box informing that "The Windows Phone Emulator wasn't able to create the virtual machine: Generic failure" appears. Really informing, really professional - generic error, that's really good. Then the information that deployment failed appears (thanks a lot for keeping me informed about that, I didn't noticed that it crashed completely). And then in the Error List, there is an information about "Invalid pointer" - even better. No clue at all about what failed or what's wrong.
Can anybody help me with that? There is nothing on the internet about this topic so far and I don't know where the problem is. I scanned the Windows events and logs, but there is nothing (probably I haven't been searching properly, so please guide me through that if you can).
Anybody can help?
The Windows Phone 8 emulator requires hardware Hyper-V support. In particular, it requires second-level address translation, hardware assisted virtualization, and hardware DEP support enabled and to not be ran in a hypervisor(no nesting). If you bought your machine within the past 4 years you should have no problem with these requirements. You can check out this article to see more information about that and how to find if your PC supports it.
Because of these hardware requirements, this means you can't run the phone emulator inside of most virtualization technologies... With one exception: I've been using VMWare 9 which appears to include an "unsupported" feature to allow Hyper-V to work though.. So your only choice for running the phone emulator is to either buy VMWare 9 (or 8 with more configuration) or upgrade a physical machine to Windows 8
The unsupported way VMWare allows you to run Hyper-V inside of a VM is that there is a manual option (hypervisor.cpuid.v0 = “FALSE”) which basically tells VMWare not to report to the virtual machine that it's running in a VM. Hyper-V checks if it's running in a VM and won't work if it is, so this gets Hyper-V to work past that check. I personally have tested this whole nested-VM thing with the Phone emulator(including before public release), and other than being quite slow, it does work pretty well with no immediate crashes or anything.
There is a workaround for VMWare Workstation 8 as well in an answer below. However, 9 is much easier to configure, so if you have it use this method.
I ran into the same issue and I fixed it by enabling Hypervisor applications in this virtual machine and adding the following line to the .vmx file:
hypervisor.cpuid.v0 = "FALSE"
This got the emulator working just fine. I found this answer here.
Hope this helps.
Actually, it works quite nicely with VMware Fusion 5.0.1
All I had to do is to add to the .vmx file of the virtual machine the following lines:
hypervisor.cpuid.v0 = “FALSE”
vhv.enable = "true"
Save and restart VMWARE (obviously the VM must be stopped before the changes are made)
I'm right now debugging a test app from VS2012 using the emaulator inside a VM in my Macbook
I'm a happy camper
:-)
I posted the same question on Parallels forum.
Reply:
The emulator is actually a virtual machine, so we are talking about a vm inside a vm, this requires support for nested Hyper-V, which afaik is planned but not implemented yet, also VMWare Fusion already supports this, if you are so desperate.
————-
See Parallels forum post: http://forum.parallels.com/showthread.php?p=646448#post646448
This works for me
Set RAM to 4g
Set at least 2 cores
add to vmx file.
vhv.enable = "TRUE"
hypervisor.cpuid.v0="FALSE"
Goot article
http://social.msdn.microsoft.com/Forums/en-US/wptools/thread/ed72010c-321c-4667-97b2-3ff1540e7f87/
You need SLAT compatible hardware to run Hyper-V, which is a requirement for using the emulator.
Can you clarify what kind of hardware you're attempting to run this on, and if you have enabled Virtualization in your BIOS settings?
The "Invalid pointer" error just means it cannot connect to the emulator (and/or device).
Just as an addition to https://stackoverflow.com/a/13163762/1964969 (top answer at the moment):
manually appending "hypervisor.cpuid.v0" key works for VmWare Player 5 as well (the main reason - this software is free for non-commercial use so it's perfect product if you test the waters, just download from VmWare website and install, it's fully-functional).
Slightly unexpected, any of the following amends solve the problem with WP8 emulator:
hypervisor.cpuid.v0="FALSE"
hypervisor.cpuid.v0="TRUE"
hypervisor.cpuid.v0=""
Yeah, you can apply empty value for that key - but why? Have no idea but it works. I did some notes in my blog as well:
http://windowsasusual.blogspot.ru/2013/01/how-to-launch-windows-phone-8-emulator.html
Under Parallels Desktop 8 follow this guide: http://kb.parallels.com/en/115211
Edit:
Oh, I didn't noticed that you are trying to run emulator on VM. My answer is for non-VM environment.
First of all, you need to check hardware requirement at here
Be careful, successful installation of SDK does not guarantee "your hardware is compatible"
If your hardware is compatible and Hyper-V is running(described in the link above), please check your BIOS and be sure to enable hardware virtualization in CPU Configuration
(for me, I could find it at Booting > BIOS > Advanced > Advanced > CPU Configuration)
Brief summary:
64bit CPU and OS
4GB RAM
Hardware-assisted virtualization supported CPU
Second Level Address Translation (SLAT) supported hardware
Hardware-based Data Execution Prevention (DEP) supported hardware
Proper BIOS settings
For me the solution adding line:
hypervisor.cpuid.v0 = "FALSE"
I use VMware Player and added the line (hypervisor.cpuid.v0 = "FALSE")in the .vmx file.
My virtual machine with Windows 8 Pro runs the emulator for Windows Phone 8 perfectly.
Solved the problem by uninstalling an older VPN client from the machine. It turns out some VPN clients might have compatibility issues with Windows 8. After uninstalling VPN client I was able to run the emulator without issues (of course after making sure Hyper-V was installed and enabled on the machine)
Not enough rep. to comment on the accepted answer, but Microsoft provide instructions specifically for Fusion here. It worked for me, after a couple of reboots of both Mac and VM. I installed W8.1 without Hyper-V support initially and had to install it after the fact ("Turn Windows Features On or Off" in Control Panel), but apart from that no problems. Quite speedy on a 16Gb 2013 MBP.

Old 16-bit Application Causing GPF in WIN87EM.DLL, intermittently

I've got an old 16-bit application, that was developed for Windows 3.1. It preforms some calculations and is part of a more complex system. The system sets up the inputs for the program, and collects the output results.
Unfortunately, the 16-bit program is here to stay for the mean time, so we have to work around the frustrations it causes on modern operating systems.
The system runs on Windows XP, and on physical Windows XP machines it runs alright. The machine I'm having a problem with, is a Windows XP instance running on VirtualBox (version 4.1.12) on a Debian box. The physical computer is an HP Proliant server, with Quad Core Xeon 3.4 Ghz. I'm using remote desktop to access the computer from my Windows 7 box.
The error I'm getting is, "PROGRAM caused a General Protection Fault in WIN87EM.DLL at address : 0001:02C9". The annoying thing is, at times it works and other times it doesn't, making troubleshooting all that more frustrating.
From trawling the internet, I've come across a few sites that mention the same problem. None of them seem to offer real solutions, except to say that WIN87EM.DLL supplies floating point routines, and has some issues with certain printers.
I've uninstalled all printers on the virtual machine, I've also tried installing a PDF writer and setting it as the default printer - so that there is a printer on the machine. I've disabled resource sharing with my Remote Desktop connection. I've updated the Virtual Machine Guest drivers on the machine. I've also tried setting the compatibility to Windows 95 in the properties of the executable.
Any pointers for troubleshooting this problem, or methods I could try to get it working?
This question is old but I had this exact win87em.dll crash with some 16-bit factory automation software running natively on windows 7. By following the method of HIDE87.com and editing autoexec.nt I was able to make the software stop crashing so that I could make edits.
This machine was running Intel 8 Series/C220 Series chips. I attribute this configuration to the crash because I have used this same 16-bit software on tons of other windows 7 machines for years now.
edit: here's the steps I used to fix the problem
Download winfloat.exe from http://www.conradshome.com/win31/archive/
Open winfloat.exe with 7zip. Find HIDE87.com and extract it to desktop.
Copy HIDE87.com to C:\Windows\System32\
Open c:\windows\system32\autoexec.nt with notepad
At top of file, after first group of comments add the following
lh %SystemRoot%\system32\HIDE87.com
Add a comment above your last line
REM Fix for Gen. Protection Fault in win87em.dll
Save changes to autoexec.nt and reboot pc.
This was the same error I had with Microsoft XP Mode.
Obviously WIN87EM.DLL has Problems with virtualized processors.
My Solution: I "unloaded" the XP-Version of WIN87EM.DLL in the registry (search and delete every item with this name), and copied a much older version into application folder. The old version can be found her: http://support.microsoft.com/kb/86869/de
Good luck!
Video Driver win87em.dll
This is the step by step resolution to the problem we had with the “win87em.dll” issue.
Left-Click the START button in the bottom left corner of the screen.
Right-Click My Computer and left click Properties.
Left-Click the tab at the top that says Hardware
Left-Click the button that says Device Manager.
Left-Click the + sign next to Display Adapters near the top of the list.
Right-Click the items shown in the expanded list under Display Adapters and left-click Disable.
Left-Click the Yes button that shows when windows asks if you are sure you want to disable it.
Left-Click the No button when windows asks if you want to reboot.
Repeat the disable process for each item listed under Display Adapters (usually only one or two)
Reboot the PC and the win87em.dll General Protection Fault errors should go away.
This is only applicable for users on Windows XP. Most likely the display adapters listed will be shown as an Intel G41 internal display adapter, but it may be another Intel device. If this does not fix the issue then it is likely a bad printer driver causing the problem.
Disabling the video adapter will not hurt windows. It will make their computer unable to watch videos or play 3D games, but windows will still run and look fine. (They will probably need to change their screen resolution after rebooting.)
VirtualBox 4.3.16 should also have a fix. See https://www.virtualbox.org/ticket/12646 If you want the fix immediately, you'll have to build VirtualBox from OSE sources.
Update: VirtualBox 4.3.16 containing this fix is now officially released.
I know this is an old thread but I came across it while searching as I was having the same issue under Windows XP running VirtualBox. Eventually I found the following:
https://communities.vmware.com/people/jmattson/blog/2012/03
This is for VMWare and seems to have fixed the issue, couldn't find anything similar for VirtualBox but as VMWare Player is free it is a good workaround for anyone having this problem.
in the case of virtual machines - vxBOX (tested) of VM ware (maybe)
you just have to switch off all para virtualization options in the processors section of VX BOX options.
works like magic!

XCode compiling extremely slow inside VMWare

The OSX 10.6.6 is installed inside VMware on Windows 7 host. The overall performance is great, However, the compiling time increased dramatically (1 hour against 2-3 min on pure MacOS). It's modern machine with Core i5 & 4GB RAM.
Here are the XBench results:
http://db.xbench.com/merge.xhtml?doc1=517768&doc2=1&setCookie=true
I think the problem could be in extremely slow 4k write value, but I don't know how to improve this.
Is there any way to increase performance?
UPD1: swap is not used, there is enough memory for all operations
the disk speed is also not related, since my another Macbook shows event worse results, and compiles hundreds times faster.
UPD2: problem solved, see my answer below
Sharing experience and solution.
My Xcode was running fine but when I build a project (even an empty one), it would take up to 10 minutes.
SOLUTION:
Go to Xcode -> Preference -> Source Control: Dissable Source Control
Now projects build and run in a matter of seconds.
In VMWare, you should have a setting where you can dedicate one or two cores entirely to the virtual machine. Assuming you have quad core, maybe give MacOSX 2 or 3 cores? If you have dual-core and you've allocated 1 core to the VM (and the problem still persists), i can't say much then!
It's good that your problem is solved, but I want to share my experience for improving vmware performance. Please do install VMware tools for mac os and they are present in .iso file.
Steps to install VMware tools for MAC OS:
1) Power on your VM.
2) At the right bottom they are some pop-up symbols(These are usually not present in full screen mode). Rightclick the CD/DVD symbol.
3) Click setting. In this window make sure that darwin.iso is selected.
4) Close this window and again right click CD/DVD symbol.
5) Click connect. An icon will appear with name darwin(300).
6) Inside this file tools are present. Install them!
The problem was: VERY SLOW recursive searching of include paths. If non-recursive, everything works smooth.
I also got the same problem, But i want share my personal experience here.
My CPUs RAM capacity is 4 GB, So i allocated 3.5 GB to the VMWare
because of this it was very slow the entire operating system.
So one day i clearly observed the VMWare settings, finally found the
solution. If we allocate the RAM memory more than recommended then
also your operating system hangs. For my System the recommended RAM
memory is 2048MB, after adjusting this now OS is fast.
We can adjust the RAM memory in Devices option, inside Hardware. For
clarification here i am attaching the screen shot.
I had the same problem and I fixed it as follow:
Most boost I got with changing my vmware config file to disable memory
stored in .vmem file. In my .vmx file I added :
mainMem.useNamedFile = "FALSE"
prefvmx.minVmMemPct = "100"
Setting max cores to the guest
When programming with swift and XCode. Remove all comments /* */ not really used.

How should I install Linux on Windows Vista PC? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 7 years ago.
Improve this question
I am doing .net programming in addition to c and c++ development and want more flexibility on my home machine. I want to be able to have both Linux (probably Ubuntu) and Windows Vista on my home computer. Is there a way I can install both and on boot be prompted for which one to start? Is there a way to set Windows to default?
I have seen this before in CS labs in undergrad.
Also, I assume there would be no problem if I were to use Windows 32-bit along with Ubuntu 64-bit. Any advise?
The latest versions of Ubuntu include an installer called Wubi, which installs Ubuntu as a windows application (ie: it can be uninstalled from Add/Remove programs) and sets up the dual boot for you! It's great for those who want to give Linux a try without a system overhaul!
You can dual boot, but I would recommend using a Virtual Machine for what you want to do.
Look at VMWare and Virtual PC.
For more information on Virtual PC: http://en.wikipedia.org/wiki/Microsoft_Virtual_PC
For more information on VMWare: http://en.wikipedia.org/wiki/VMware_Workstation
You should note that dual booting Windows and Linux can be a little risky and is a bit permanent. Running in a Virtual Machine means that you can run the Linux install in a window and not worry about it affecting your development machine at all. The software will not know the difference, so your testing is not affected.
Consider that the Virtual Machine is like a sandbox, where you can try new and different things out, without fear of consequences.
Virtual machines do run with a bit of overhead, and therefore you should not expect to be playing games or anything through them. I would say it is very much like logging into a machine through Remote Desktop (good LAN connection) as far as performance goes.
EDIT: There is also VirtualBox that you could check out. Thanks for the helpers in my comments for that one.
I, too, recommend using a virtual machine for this purpose.
I've had problems with Virtual PC on some Linux distros (Fedora Core comes to mind), but no problems with VMWare or Virtual Box.
Think very hard before installing another operating system even as dual boot. It is rarely simple, even with installers like Ubuntu's that don't require you to mess around on a command line. There is a good risk you'll spend days trying to get your usual OS back to normal especially if you're using Vista.
VMWare and Virtual PC are both good options. Do a test install on one of these and use the OS for a while before making the decision to install.
One other great thing about using a virtual machine is that you only have to worry about getting your network settings sorted on your main OS, because VMWare (etc) will borrow those.
Also, try using the operating system on Live CD or DVD to start with if at all possible. You may also find that you can run an OS from a USB stick. This is obviously good for portability - but note that you can also carry your virtual machines on a removable USB drive.
All you have to do is go to http://www.ubuntu.com/getubuntu/download and follow the directions. I downloaded Ubuntu, burned it to CD, and rebooted with the CD in the drive. I did not have to get a second hard drive or worry about it messing with my Vista Home Premium installation.
With Ubuntu (as with most distros with a Live CD install) all you need to do is pop in a disc, boot, and click through the menus. The dual boot is set up perfectly by default, you don't even have to think about it. I've done this with Ubuntu, Debian, PC Linux OS, Freespire, and Xandros on my Vista Home Premium machine and they all worked that way.
If you are paranoid, then you should back up your PC. As cheap as hard drives (USB or internal) are these days, there really is no excuse to not have a full back up of your system. It's too easy. I use Acronis True Image, but I've heard good things about Norton Ghost as well.
Regadless, you don't need Wubi or VMWare, or any virtual anything, a straight install with a dual boot set up is the default on a typical Live CD Linux install and it works even with Vista.
I've done it different ways over the years, and I'd say using a virtual machine is the one that I like best. I've tried both VMWare and VirtualBox, both free, and I like VirtualBox a little better because you can use it with the .iso straight. You don't need somebody to have created a virtual machine image for you.
Another option is to actually run Linux as an application on Windows so you get Linux running at almost full speed but also the ability to run Windows applications along side it. Check it out at http://www.colinux.org/.
I haven't had a chance to play with it yet, but an option that looks promising for me is a tool in Ubuntu to create a bootable USB drive with Ubuntu on it. It has the benefit of a live cd (no effect on your system), better performance than a live CD and the ability to persist your data from session to session. I've used Wubi before, but I can't remember why I uninstalled it.
Have a look at "cygwin".
This istalls a "linux like" windowing application within your windows
environment. It has good support for gcc and most of the standard
gnu/linux development tools.
You dont have to mess with dual boot. Its especially good for testing
windows to/from unix communictions as you can get everything up and
running in one box.
What you're looking for is called 'Dual booting'. it allows one to choose which operating system to boot at the start. It's well supported in Linux, especially Ubuntu. Just install Ubuntu and it will set up dual booting by default.
You could go either way, a dual-boot or use a VM. I think it depends on whether you'll want to use any Windows apps while developing in the Linux environment. If so, I'd go with a VM, otherwise, here's a tutorial for setting up a dual-boot computer. It has a part on installing both OSes, and a part on if you already have Windows installed.
Wubi is a great (Ubuntu specific) solution.. The only problem I've found was installing Wubi on a FAT formatted Windows partition - I had serious problems then. Also, it might run slightly slower, as there is another layer when doing disk acccess, but I can't say I've noticed.
I dual boot Vista Ultimate 32-bit and Ubuntu 8.10 beta 64-bit with no problems. The key thing, in my opinion, is to have a completely separate hard drive to install Ubuntu on. That removes a lot of the risk since you don't have to fuss around partitioning your primary HDD and makes removing Ubuntu very straightforward as well if you decide you don't want it.
Just be careful and pay attention on which drive you select when you do the install. It's easy for me to tell them apart since my Linux drive is a different size than my main Vista and data storage drives.
If you'd rather go the VM route, VMware Player works well, and I've heard good things about VirtualBox.
try a live cd install of ubuntu :D
creating a bootable flash disk is easy - unetbootin from sourceforge.net
I have dual booted Ubuntu and Xp many times with absolutely no problems. I doubt you could do the virtual thing with one OS 32 bit and the other 64. This would not be a problem with a dual boot.
I have had problems using wubi and my boot into windows7 is now unstable at best, so given the choice would favour a VM solution in hindsight. However on other machines I have run Ubuntu Live on USB (installed using pendrivelinux.com) by picking the try ubuntu option at boot and that has worked well and was quite quick to get going.

Resources