machine lag really bad when operating 6 VM's

Posted on 2008-10-16
Medium Priority
Last Modified: 2012-05-05
My system:
processor - intel core 2 quad Q9550 2.83 GHZ
memory - 4gb ram ddr II 800mhz (2*2 dual channel )
storage - seagate 320GB 7200 rpm 32mb

Host - windows xp pro sp3
guests - xp sp3 512mb

there is one "custom made" operation system (xp) and all the rest are cloned - LINKED clone, not a full clone.

when i run 6 VM's ( i run the 1st, than after the 1st finished booting i run the 2nd ....etc )  my machine lag really really bad! and im not even running anything , just the guest xp.

when i check cpu usage and memory usage to see if it's full than i see that everything is alright!
cpu usage is about 10-20 % and memory usage is only 880mb\3200mb (why xp doesnt recognize i have 4 gb?)

i have no idea what can cause my system to lag that badly even though cpu and memory are not even sweating...also when checking core temp , motherboard temp etc. i see nice results around -35c-50c

can it be the hard drive? i find it very hard to believe!
maybe the power supply ? it is 500w, should i buy 550? 600?
maybe because it's linked clone and not full clone?

im desperate here please give me some advise good fellas it's urgent...

thanks in advance, really looking forward to hear from you!

-ps viruses spyware etc are out of the question since the machine works perfectly while using 2-4 vm's

Question by:sheleg
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
  • 2
  • +1
LVL 42

Assisted Solution

paulsolov earned 600 total points
ID: 22737013
If you're running windows xp with onboard devices you'll get about 3.2-3.5GB memory total because of the onboard devices taking the rest (video card, etc..), especially on laptops if you are using it on one.

XP on its own is running about 500-700MB leaving you about 2.5GB of RAM for the virtual machines.  6 guests * 512MB RAM = 3072MB which means the system is paging a lot and thus using the hard drive for memory (page file)

Try scaling down the memory on each guest to 200 and see what happens.  Running 6 guests on a 7200 rpm drive may cause some I/O issues but you'll have to monitor it.

My $.02

LVL 70

Assisted Solution

garycase earned 1000 total points
ID: 22737030
First, XP doesn't "see" a full 4GB because there are system level resources that much be assigned addresses within the 4GB address space; and these are assigned BEFORE any address space is allocated to the RAM.   These are things like video aperture, BIOS shadowing, PCI bus addresses, etc.   Depending on the amount of video memory you have, you'll typically see between 3 and 3.6 GB on a system with 4GB installed.   So that's normal.

As for why your system bogs down when you load 6 VM's ==> Your VM's have been assigned 512MB each.   When you load a VM, it allocated 512MB of memory for that VM.   This happens again for EACH VM you load.   At some point (I'd actually think it'd happen at about the 4th or 5th on your system) you'll hit a point where there isn't enough physical RAM available for allocation of the requested RAM, so you'll start having a very high instance of page faults [When the system has to "swap" physical memory out to virtual space to allow the process that needs the memory to be given more RAM].   By the point you load the 6th VM, this is happening even for OS functions ==> you've simply tried to allocate more memory than the system has, and EVERY activity you do causes a page fault.

This is normal ... and there's nothing you can do to eliminate it with your current virtual setup.  

You could change the point at which it occurs by modifying the memory allocation for the virtual machines -- for example, if they each were allocated 256MB you could probably load 6 with no problem -- but you'll still get the issue if you load more VM's than you have physical memory to accomodate.

Another more involved way to eliminate this would be to install a 64-bit OS (XP or Vista) and install a large amount of memory (8 or 16GB).   Then there'd be much more memory available for the VM's.

Author Comment

ID: 22739015
thank u for the reply.

i must emphasize that when looking at task manager =>performance  i see that less than 1GB ram is being used(!) so i really can't understand why u say that there is not enough memory?
 and when looking at each vm's memory usage it consume less than 350 out of it's 512 assigned...
so i can't see how ur saying it uses all the memory since it shows only 900mb TOTAL..

looking forward to your reply and thannks in advance
Building an interactive eFuture classroom

Watch and learn how ATEN provided a total control system solution including seamless switching matrix switch, HDBaseT extenders, PDU, lighting control to build an interactive eFuture classroom.

LVL 42

Accepted Solution

paulsolov earned 600 total points
ID: 22739451
Since the hardware is virtualized looking in task manager of each virtual machine will not give you correct results.  Since vmware is doing the scheduling of memory and cpu task manager is not a good tool to use and will not give you correct information.  Use Vmware to guage how much memory each vm is using

Author Comment

ID: 22740676
i will look into it on Sunday, reduce memory to 250 per machine and we'll see if thats the prob.
LVL 70

Assisted Solution

garycase earned 1000 total points
ID: 22742861
Task Manager shows the memory allocated to Virtual PC, but not to its subordinate processes => this is a "glitch" that is due to the interaction with the virtualization code.   For example, I just started up 9 virtual machines -- a copy of Vista, two copies of XP, 2000, ME, NT, 98 original, 98SE, and 95 -- and task manager only shows 54MB in use by Virtual PC, although the virtual machines occupy a total of 2280M.    With all these running, my system still works just fine -- no sluggishness at all => and I've got 3 browser windows, Word, and Thunderbird running in addition to the VM's.

But if I load another MB worth of virtual machines my system will get VERY sluggish -- for exactly the reason I noted earlier.   As noted before, if you reduce the memory in your virtual machines to 256M, you'll be able to run 6 at once with no problem -- the issue you've experienced will simply change to a different number of VM's.

Of course in addition to the major slowdown caused by excessive page faults -- which is what you've described -- the more VM's you load, the lower the performance of the individual virtual machines, since there's only one "real" CPU to do all of the processing :-)    
LVL 18

Assisted Solution

larstr earned 400 total points
ID: 22753128
Yes, The limiting factor here is mainly your disk. That 32bit XP can't use your full 4GB is another limiting factor, but that wont slow you down much as long as there is available memory in your system.

While your VMs are powered off try editing each VM's .vmx config file and add the following settings:
MemTrimRate=0sched.mem.pshare.enable = "FALSE"mainMem.useNamedFile = "FALSE"

These settings will give you better performance at the cost of using more memory of your system. Reducing RAM for your VMs will also reduce the amount of disk accesses so do not give your VMs more ram than they need. You should also give each of your VMs only 1 virtual cpu to begiun with and only give them extra virtual cpus later if they really need it.

LVL 70

Assisted Solution

garycase earned 1000 total points
ID: 22753381
"... The limiting factor here is mainly your disk ..." => NO !!   The issue here is physical memory --> when too many machines are loaded, there's simply not enough memory to keep them from causing excessive page faults ... which is slowing the performance drastically.   Eliminate that and they'll work fine (within the bounds of the available CPU "horsepower").    I have 45 virtual machines on my system (24 in Virtual PC; 21 in VMWare) => disk space and/or performance isn't an issue as long as there's "enough" space and the VM's aren't all doing disk-intensive activities at the same time.   The only "disk" issue is the dramatic slowdown you get when you're getting constant page faults on memory accesses.    As long as you don't try to load too many VM's simultaneously they'll perform fine ... as soon as you cross that threshold you'll notice a BIG slowdown as you start causing major page fault activity => THAT is what's happening in the issue described in this question.

Also, note that the first two options suggested above (MemTrimRate & sched.mem.pshare.enable) will reduce VMWare's ability to share physical memory among virtual machines => and will make the issue described here WORSE ... you'll run out of physical memory earlier when loading many virtual machines.


Author Comment

ID: 22753405
reduced each vm to 256mb
swift to x64 xp host os

using full cloned vm gives u exact indication about how much memory it consumes.
now working real nice...though not nice enough...next machine would be with sockets for cpu...
LVL 70

Expert Comment

ID: 22753421
If you are going to run a large number of VM's simultaneously, you may want to consider using a server motherboard that supports dual quad-core Xeons.   With 8 cores [More with the next generation of chips] you can run quite a few simultaneous virtual machines with excellent performance on each.   And of course if you load it with lots of memory (16GB or even more) you shouldn't encounter any page fault issues unless you load a LOT of VM's !! :-)

Featured Post

Create the perfect environment for any meeting

You might have a modern environment with all sorts of high-tech equipment, but what makes it worthwhile is how you seamlessly bring together the presentation with audio, video and lighting. The ATEN Control System provides integrated control and system automation.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this article, I will show you HOW TO: Create your first Windows Virtual Machine on a VMware vSphere Hypervisor 6.5 (ESXi 6.5) Host Server, the Windows OS we will install is Windows Server 2016.
Giving access to ESXi shell console is always an issue for IT departments to other Teams, or Projects. We need to find a way so that teams can use ESXTOP for their POCs, or tests without giving them the access to ESXi host shell console with a root …
Teach the user how to install and configure the vCenter Orchestrator virtual appliance Open vSphere Web Client: Deploy vCenter Orchestrator virtual appliance OVA file: Verify vCenter Orchestrator virtual appliance boots successfully: Connect to the …
How to Install VMware Tools in Red Hat Enterprise Linux 6.4 (RHEL 6.4) Step-by-Step Tutorial
Suggested Courses

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question