Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a Windows 7 64 bit with lots of RAM hosting a VirtualBox VM with a Windows XP guest. The apps run on the guest use so much ram that it typically ends up swapping.

I'd like to know any tips for configuring the guest or host so that the guest gets best use of the hosts RAM as a disk cache (particularly for the swap file?)

In particular, is there any way to get the Win 7 host to use most of its RAM as a disk cache (or will it do that anyway)?

Should I change any settings in the XP guest to run well in this environment?

share|improve this question

closed as off topic by Shane Madden, Zoredache, Wesley, Scott Pack, Ward Sep 29 '11 at 4:50

Questions on Server Fault are expected to relate to server, networking, or related infrastructure administration within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.

How much memory does your Windows 7 machine have? How much memory do your virtual xp box have, are you running more than one virtual host? How much RAM does your applications require? Add more memory is the simple answer. – Nixphoe Sep 29 '11 at 0:26
@Nixphoe -- The Windows 7 machine has 16 GB; I've given 4 GB to the guest (the maximum Win XP 32 can use). The Windows XP guest application load ends up using 6 or 7 GB of virtual memory. – antlersoft Sep 29 '11 at 3:44

I think that you're confused about how VirtualBox (or any other VMM or hypervisor) software works with a Windows guest.

There are two file systems, the one for the host and the one for the guest. The host doesn't see guest files as they are read or written, only blocks in the virtual hard disk file(s). So the host file system can't really cache those files.

It could cache the blocks of the virtual hard disk, but the guest OS is already doing that. So most designers of virtualization systems (VMMs and hypervisors) choose not to use that RAM twice, prefering to make the guest's virtual disk files uncached in the host.

If you want the guest to do less swapping, give it more memory.

share|improve this answer
The guest is Win XP 32 and can only handle 4 GB of RAM, which I'm giving it. I'd like it to be able to take advantage of the 16 GB in the host for disk caching (or some other way.) With VirtualBox, you can choose to turn host caching on or off. – antlersoft Sep 29 '11 at 3:46

Not the answer you're looking for? Browse other questions tagged or ask your own question.