WinXP Guest - with or without pagefile?

Discussion in 'Parallels Desktop for Mac' started by Olivier, May 8, 2006.

  1. Olivier

    Olivier Kilo Poster

    This is obviously more a support question than a beta testing question. But it is anyway a question from a licensed customer.

    I understand that PW does itself buffer disk I/O from the VM to the virtual HDD (if it doesn't, then my question will be flawed from the start, but it looks to me it actually buffers or optimize virtual HDD access on behalf of the VM).

    Based on this assumption, would it be valuable for performance tweaking reasons to configure the guest Win XP to use NO pagefile and eventually give it more RAM?

    My typical working set seems to establish itself around 200 to 250 MB (in the guest OS). I am wondering what would be best for optimization of resources and best overall performance, both of the guest *and* the host. More guest RAM without pagefile, less (== just enough) guest RAM, but a pagefile ? What about the maximum amount of memory that we can let PW use ? Should it be set as high as possible, as low as possible ?

    Assuming a 512 MB RAM guest. Should the Common Memory Options (from PW preferences) be set as close to 512 MB as possible? Or higher? I understand higher is required to get good performance out of multiple VM running at the same time. But in case of a single 512 MB, would setting CMO at 1 GB instead of let's say 600 MB be a positive move for performance?

    The product runs very fine for me, except some known issues with the current beta 6. So I'm just trying to gather rules of best configuring it.
  2. tacit_one

    tacit_one Kilo Poster

    1. It is better to keep your CMO a little bit higher then total amount of memory allocated for all your virtual machines (about 80-100mb overhead for each VM should be assumed)
    2. Enabling or disabling pagefile inside your guest system will probably not affect overall system performance, but may lead to the lack of virtual memory for some guest applications that is why it is better to enable it
    3. Amount of memory allocated for your VM configuration greatly depends on applications you launch (however, the more memory you will bring your guest system, the better results you will get)
    4. Even if you will set 800mb for your guest system Parallels Workstation will not allocate it untill your guest applications will use it
    5. Swapping in either guest system or primary system will lead to great performance loss - if you experience high disk i/o on memory related operations you probably need to reconfigure your applications
  3. Olivier

    Olivier Kilo Poster

    Thanks for your answer.

    So, if my guest OS is very happy with 384 MB and doesn't really benefit from more, I should leave it that way and set CMO to let's say 512 MB (128 MB more than VM). Right ?

    In such a case, keeping the VM at 384 MB and setting the CMO at 1500 MB (I have 2 GB RAM in the host) won't be beneficial. Right ?

    Now, if I choose to 'upgrade' the VM to 512 MB or more and increase CMO just enough accordingly, my XP guest will use most of this memory for disk cache. But wouldn't it be better to *minimize* the disk cache of the guest, so to run with a slightly smaller VM, and benefit from the host disk caching ?

    In other words, for the net virtual disk I/O performance inside the VM, would the guest OS caching be more effective than the host OS disk caching or the reverse ?

    I understand the answer might be very different depending on the guest OS, but for a typical XP guest, do you have suggestions about this ?

    I'm busy trying various configurations and it looks like Mac OS X caching is more efficient than XP guest caching. Though I need more time and more tests to assert this for sure.
  4. drtimhill


    You'll probably never get a perfect answer to this, because there are so many variables. I agree with you that Mac OSX caching is probably more efficient overall than WinXP in a VM, and so reducing the amount of RAM available to the WinXP VM should help overall performance. BUT it takes considerably longer to fetch a disk block from the native OS X cache after a WinXP virtual cache miss than it does if WinXP got a cache hit.

    My instinct is that the "correct" answer depends on your workflow. If you tend to switch into WinXP and spend large amounts of time there, then switch off the VM and go back to OS X, then my feeling would be to give the VM more RAM and let XP caching do its job. If, otoh, you switch back and forth, or run active apps in OS X and XP at the same time, you're better off reducing XP cache.

    XP Performance Monitor will help here. Watch the "inpage" and "outpage" counters to monitor page swapping (not the "soft" page fault counters). Reduce VM RAM until you see a sudden jump in the swap activity, then back off. That's (roughly) how much RAM you need for that application.

  5. colourpixels


    can't have zero pagefile

    My recollection from when I was looking into running ramdisks as the pagefile, was that even if in windows you set the pagefile to be zero in size, widows still actually has swapfile, you just don't get a say over where / what it does. I'm sure someone wiser than I can point to somewhereon the web explaining it.

  6. wesley


    Your recollection is correct. The whole Windows memory mapping doohicky REQUIRES at least certain minimum amount of swap file. If there's none you're bound to run into some sort of error saying insufficient memory even if you have 2GB of RAM. I'm guessing that the best way to go is to set as little a swapfile size as possible that does NOT cause the insufficient memory error.

Share This Page