cancel
Showing results for 
Search instead for 
Did you mean: 

Problems and lags while running Virtual machine

dav_simonyan
Level 7
Hi, I noticed a few problems during running Windows 7 Ultimate 64bit via Virtualbox on my Asus G751JM.

1. If I assign 4 CPU's(with 8GB of Ram) to VM then Guest OS starting lagging especially on animations(Windows 7 booting animation, scrolling). On my home PC(i5 2500, 8GB Ram) I could easily assign 4 CPU's with 5GB Ram and VM works perfectly, only host OS lagging. On Asus g751 Guest OS works as expected only when I assign 2 CPUs instead of 4(and a little faster than my home PC while compiling).
2. When I scroll pages with 2 fingers in VM by touchpad very often(at least once from every 5-10 scrolls) notebook give a sound signal(I think not from speakers, from motherboard maybe?) like beep-beep and the scrolled window starting to lag. If I scroll via mouse everything is ok.

Specs:
i7 4710 HQ
24GB DDR3L RAM(2x4GB Kingston + 2x8GB Corsair Mac Memory Kit)
2x1TB HDD 5400rpm
GTX 860m GPU

I decided to turn off Windows 8.1 and Geforse updates when I bought this notebook. Geforse driver version currently is still 333.37.

Any ideas?
13,567 Views
11 REPLIES 11

hmscott
Level 12
dav.simonyan wrote:
Hi, I noticed a few problems during running Windows 7 Ultimate 64bit via Virtualbox on my Asus G751JM.

1. If I assign 4 CPU's(with 8GB of Ram) to VM then Guest OS starting lagging especially on animations(Windows 7 booting animation, scrolling). On my home PC(i5 2500, 8GB Ram) I could easily assign 4 CPU's with 5GB Ram and VM works perfectly, only host OS lagging. On Asus g751 Guest OS works as expected only when I assign 2 CPUs instead of 4(and a little faster than my home PC while compiling).
2. When I scroll pages with 2 fingers in VM by touchpad very often(at least once from every 5-10 scrolls) notebook give a sound signal(I think not from speakers, from motherboard maybe?) like beep-beep and the scrolled window starting to lag. If I scroll via mouse everything is ok.

Specs:
i7 4710 HQ
24GB DDR3L RAM(2x4GB Kingston + 2x8GB Corsair Mac Memory Kit)
2x1TB HDD 5400rpm
GTX 860m GPU

I decided to turn off Windows 8.1 and Geforse updates when I bought this notebook. Geforse driver version currently is still 333.37.

Any ideas?


dav.simonyan, it's your drive(s) unparking and spinning up that makes the noise, and the lag.

You can ameliorate some of that lag by disabling APM for the drive.

quiethdd is only supposed to disable/control APM/AAM for the boot drive, so if you have your VM sourced from the 2nd Bay drive, it won't help - but it will help anything run from the boot drive.

Please let us know if you notice both drives affected, I think you are the first that has mentioned they have 2 HDD drives installed - and using quiethdd.

quiethdd - stops drive noise/clicks and game/app pauses/freezes due to APM.

https://sites.google.com/site/quiethdd/

Put these config lines in the quiethdd.ini file

FirstRun = 0
AC_APM_Value = 255
DC_APM_Value = 255
AC_AAM_Value = 254
DC_AAM_Value = 254
AAMEnabled = 1
APMEnabled = 1

And/Or use the GUI to set APM/AAM to 255/255, and use the systray app to disable APM.

46224

Any other slow lag (slag?), will be due to slow HDD transfers when loading VM resources.

Please come back and let us know how it works out 🙂

xbi0s
Level 7
VirtualBox has always given me some lag and a poor user experience. I only use it for my Malware analysis anymore.

You can get VMware Player for free... Allows you to have a better user experience but you do suffer with having less options from a networking perspective unless you get Pro.

Also, I am assuming you have installed VirtualBox Guest Software on the Guest machine?

dav_simonyan
Level 7
Hi hmscott, I don't think its due to APM(at least the core of the problem) because it works great when I use mouse instead of touchpad. I think its somehow related to touchpad. And regarding HDD, I moved *.vdi file from second HDD to system HDD(but not to system local drive) and it still lagging on 4 CPU(no lags for 1 or 2 CPUs). So seems its not related on which HDD I have *.vdi files.

Then I do some tests with CPU amount assigned to VM:

Rebuilding Project 1 (configured for multithreaded build)
Asus G751
1. 4 CPU - total lagging on beginning, not checked building time
2. 2 CPU ~ 2 min 10 sec (by 3 attempts)
3. 1 CPU ~ 1 min 25 sec (by 3 attempts)

Home PC - (i5 2500 3.3 - 3.7 GHz, 8GB Ram, GTX 550 Ti)
1. 4 CPU ~ 1 min 35 sec
2. 2 CPU ~ 2 min 5 sec
3. HOST with 4 CPU ~ 55 sec

Project 2 (configured for multithreaded build)
Asus G751
1. 4 CPU - total lagging on beginning, not checked building time
2. 2 CPU ~ 2 min 16 sec (by 2 attempts)
3. 1 CPU - 2 min 20 sec (by 2 attempts)

Home PC - (i5 2500 3.3 - 3.7 GHz, 8GB Ram, GTX 550 Ti)
1. 3 CPU ~ 2 min 15 sec (by 2 attempts)
2. 2 CPU ~ 2 min 27 sec (by 2 attempts)
3. 1 CPU ~ 2 min 53 sec (by 2 attempts)

So on Project 1 single CPU shows better performance than 4 CPUs on my home PC on VM. On Project 2 there is only 4 sec more compilation time with single core than with 2 cores so its not relevant, and only 5 sec difference between notebook single core and 4 core on i5.

So I guess its OK to use only one CPU.

xbi0s, I am not familiar with VMWare and all my VM's(about 5 VM) are on VirtualBox, but I will check VMWare player sometime. And yes, I have Guest additions installed. WHen I move vdi files to notebook I removed old Guest additions(3.18) and installed the new one(4.20) for new VirtualBox on notebook.

dav.simonyan wrote:
Hi hmscott, I don't think its due to APM(at least the core of the problem) because it works great when I use mouse instead of touchpad. I think its somehow related to touchpad. And regarding HDD, I moved *.vdi file from second HDD to system HDD(but not to system local drive) and it still lagging on 4 CPU(no lags for 1 or 2 CPUs). So seems its not related on which HDD I have *.vdi files.
Then I do some tests with CPU amount assigned to VM:
Rebuilding Project 1 (configured for multithreaded build)
Asus G751
1. 4 CPU - total lagging on beginning, not checked building time
2. 2 CPU ~ 2 min 10 sec (by 3 attempts)
3. 1 CPU ~ 1 min 25 sec (by 3 attempts)
Home PC - (i5 2500 3.3 - 3.7 GHz, 8GB Ram, GTX 550 Ti)
1. 4 CPU ~ 1 min 35 sec
2. 2 CPU ~ 2 min 5 sec
3. HOST with 4 CPU ~ 55 sec
Project 2 (configured for multithreaded build)
Asus G751
1. 4 CPU - total lagging on beginning, not checked building time
2. 2 CPU ~ 2 min 16 sec (by 2 attempts)
3. 1 CPU - 2 min 20 sec (by 2 attempts)
Home PC - (i5 2500 3.3 - 3.7 GHz, 8GB Ram, GTX 550 Ti)
1. 3 CPU ~ 2 min 15 sec (by 2 attempts)
2. 2 CPU ~ 2 min 27 sec (by 2 attempts)
3. 1 CPU ~ 2 min 53 sec (by 2 attempts)
So on Project 1 single CPU shows better performance than 4 CPUs on my home PC on VM. On Project 2 there is only 4 sec more compilation time with single core than with 2 cores so its not relevant, and only 5 sec difference between notebook single core and 4 core on i5.
So I guess its OK to use only one CPU.
xbi0s, I am not familiar with VMWare and all my VM's(about 5 VM) are on VirtualBox, but I will check VMWare player sometime. And yes, I have Guest additions installed. WHen I move vdi files to notebook I removed old Guest additions(3.18) and installed the new one(4.20) for new VirtualBox on notebook.


dav.simonyan, you can try VMware instead of Virtualbox, but I use Virtualbox, 4 CPU's allocated - 8GB for Windows 10 VM's, 4GB for Linux VM's, and I don't see any lag. Watching CPU usage on Windows 8.1 Host I see 50% CPU utilization under load for each VM I have built, so they all are allocating and using all the resources assigned to the VM.

I do recall Windows 7 VM's would only use 1 CPU when I first made them, but VirtualBox and VMware Workstation have improved since then, I would think it should take advantage of as many Cores as you assign.

Please post your VM settings / tuning past the 4 CPU / 8GB settings. Here are the ones I use for Windows 10

46227

Did you bump up the video memory, and enable IO APIC? What about Nested paging, PAE, etc, what did you change from defaults?

It's weird that from 2 to 4 CPU's the lag kicks right in. I wonder if there is a problem with Hyperthreading, somehow when you assign all 4 cores you are locking out the Host OS from adequate resources.

Did you try turning down the % Execution Cap? I can get lag if I bump it all the way up to 100% and have other things competing from the Host OS side. Try setting to 80% to start, then bump up till you get lag.

46228

Also, for the Touchpad component, keep using an external mouse and disable the Pointing Device in the BIOS - some have had problems with keyboard lag even in the Host OS if the Touchpad is enabled.

46229

Some have had good luck just disabling the TouchPad from Windows inside Asus Smart Gesture, but others require the BIOS disable to stop the lag they experience.

46230

I use an external wireless keyboard/trackpad with a USB dongle, so I disable the mouse with Smart Gesture and I don't have any lag.

dav_simonyan
Level 7
Thanks for such detailed replay! Here is one of my VM's settings:
46236
46237
46238
46239
46240
46241

I tried to use 4 cores with 80%, but it takes the same time or longer as for 1 CPU assigned, also tried set 4 cores with 50%, that made compilation time longer about 1.5 times. For 3 cores with 100% building takes 10 seconds less(1 min 55 sec) than for 2 cores and 20 seconds less than for single core but I starting get lags on windows booting scene(not so much as for 4 cores but still noticeable). Also for 3 or 4 cores I checked host CPU usage ant it shows about 50% but the frequency of CPU was changed during compilation from 2 to 3.3 GHz. For 1 CPU on host shows 20% load but CPU speed was stable 3.3 - 3.4 GHz for the whole compilation time.

Also I tried to open a simple windows game to check animation speed there and get this warning:
46242

I tried to turn on 2D and 3D graphics acceleration for VM but that not help, I still get that message. I think its somehow related to boot scene lagging problem.

I checked yesterday BIOS and as I remember hyper threading was turned on. What related to touchpad, it works good on host and under VM also if I'm not scrolling, but I mainly use mouse so there is no need to turn it off(at this time 🙂 ).

hmscott
Level 12
dav.simonyan, Windows 7 x64 only recognizes 2 sockets / single core CPU's, so it is only going to use 2 Cores 🙂

http://serverfault.com/questions/101434/why-does-my-windows-7-vm-running-under-linux-kvm-not-use-all...

"I suspect the processors are being presented as single core processors in separate sockets. Windows 7 ultimate supports up to 2 socket systems, so it will use 2 processors.

I don't know if you can configure KVM to present the processors as either a single quad core CPU or 2 dual core CPUs, which should resolve the problem."

Now that I think back, this is it 🙂

You should be able to verify by looking at the Task Manager for how many CPU's/Cores are showing.

And, the use of and efficiency of multi-core back then wasn't what it is today, so you might not see much improvement for 2 cores over 1.

You might try using the High Performance mode Power Plan in both Host and Guest, and see if that gives you a bit more throughput.

So, setting to 2 core should be enough. Now you can run a 2nd Windows 7 x64 VM on the other 2 cores 😉

dav_simonyan
Level 7
>dav.simonyan, Windows 7 x64 only recognizes 2 sockets / single core CPU's, so it is only going to use 2 Cores

Its strange, because on i5 2500 I was able to give 4 cores to VM and in task manager it shows 4 cores.

>You should be able to verify by looking at the Task Manager for how many CPU's/Cores are showing.

On G751 under VM it shows 4 cores if I gave 4 CPU's.

>You might try using the High Performance mode Power Plan in both Host and Guest, and see if that gives you a bit more throughput.

I will check that too.

>So, setting to 2 core should be enough. Now you can run a 2nd Windows 7 x64 VM on the other 2 cores

Yes, I already tried to use 2 WIndows 7 x64 VM's with single CPU and 8GB Ram for each and it works great. 😄

Thank you very much for your help!

hmscott
Level 12
dav.simonyan, interesting, when I get a chance I will load a Windows 7 x64 to test out on my G750JH... it is odd you are getting different response on desktop/laptop. Did you enable all VM options in BIOS? The G750JH has 3 options available to enable.

46266

Can you please post a screenshot of the G751 VM options?

hmscott
Level 12
dav.simonyan, for the video acceleration error dialog above, did you try adjusting the Windows 7 Guest Hardware Acceleration Slider, as described in 2nd post/Answer here?

https://answers.microsoft.com/en-us/windows/forum/windows_other-gaming/just-installed-windows-7-and-...

And, did you update the Virtualbox Guest additions and install them in the Windows 7 Guest?
https://docs.oracle.com/cd/E36500_01/E36502/html/qs-guest-additions.html
http://www.tomshardware.com/faq/id-1955955/install-virtualbox-guest-additions-windows.html