This is the second of several tips I want to write up with regards to squeezing every last bit of performance out of Parallels Desktop for the Mac. All information below is based on the current beta of Parallels Desktop for Mac, Beta3
In my first post, i discussed hosting your VM on an external USB HD vs. your internal SATA MacBook hard drive. Today, i’ll go over basic Windows XP performance optimization.
1. Turn off all the visual effects in Windows XP.
A fresh install of Windows XP comes with all sorts of visual niceties enabled. Shadows, animated windows and cute little graphical buttons are just some of the default GUI options enabled. All of it looks good, and all of it sucks more performance out of windows than Outlook. So, first thing’s first, disable all of that stuff. Microsoft was nice enough to give us an option to do just that, but they went and hid it a little bit. Make sure your logged in with Administrator privileges, then right click on ‘My Computer’ and select “Properties”. In the system properties windows, select the “Advanced” tab, then click the “Settings” button in “Performance” group:
It’s here that we find the promised land: a option on the “Visual Effects” tab that says “Adjust for best performance”:
Select that option, and click the ‘Apply’ button. Sit back and wait for a few seconds while windows disables all of those little visual effects.
2. Use a fixed size virtual machine hard disk
Parallels gives you two options when creating a virtual hard disk, Plain or Expanding:
An expanding hard disk starts with a size of zero, and grows to meet your needs, never taking up more space than you actually need. A plain hard disk starts at a fixed size and never grows or shrinks. While an expanding hard disk sounds like a smart solution since it saves space on your hard drive, it is by far the bigger performance bottleneck of the two. Since a expanding hard disk is constantly growing and churning, you’re trading hard drive space for runtime performance. Hard drive space is cheap now a days, so pick a big size ( 20-30GB ) and create a plain hard disk of that size.
3. Turn off System Restore
If you followed tip #2, then you’ll immediately be feeling the hard drive crunch. Since you have a fixed number of GBs on your hard disk, space is at a premimum. One of the ways to keep windows from filling up your virtual machines hard disk is to turn off pesky System Restore ( SR ). While SR does provide a valuable service in some cases, most of the times it just takes up space that a ) you don’t have permission to delete and b ) won’t show up on any hard drive statistics software you run ( like WinDirStat ). To turn off SR, right click on My Computer and click Properties. in the System Properties window, you’ll see a System Restore tab. Select it and select the check box that says “Turn off System Restore on all drives”:
Click Apply, which may take a while because windows is deleting any previous system restore files. Once windows completes, click ok.
4. Move your swap file to a dedicated partition
While many people have written about the benefits of removing their windows xp swap partitions on boxes with 1.5GB+ of RAM, we still need one. It would be very difficult to run our vm’s with that much memory. ( See my previous parallels article on my findings with regards to RAM settings. ) Given that fact, there are other ways we can optimize our swap partitions usage within a virtual machine. Some of the biggest benefits can be gained by moving our swap file to a completely dedicated hard drive partition. You can change the location & size of your OS swap file by right clicking on My Computer and clicking properties. From there click on the the Advanced tab and select the Settings button in the first group under the heading Performance. Select the Advanced tab in the new window and then click the Change button at the very bottom of the window, inside the Virtual Memory group. You should be at the below screen:
From here we can alter the size and the location of our swap file and even create more than one file. Any change here will require a reboot.
Now, unless you are just setting up your hard disk file for the first time, you will probably be unable to re-partition your hard disk because you already have existing data. Fear not. Parallels supports more than one hard drive per virtual machine. So, all you have to do is create another virtual had disk file. You can do this by editing your virtual machines configuration:
Click the Add button below the window on the left. Select Hard Disk as the hard ware you would like to add. From here you create your hard disk normally. Once creation is complete, the new hard disk will be associated with your virtual machine as Hard Disk 2:
Your new hard disk will now be available with you boot our virtual machine. Format it and assign it a drive letter and you can then store your swap file there.
5. Use the Mac OS X disk caching policy option
With the release of build 1940, Parallels introduced an option to change a virtual machines caching policy. By default, caching is optimized for the virtual machine and not the underlying OS. The author of the utility PDTweaker explains it best:
“Optimizing the cache for best performance of the VM makes sense if you do nothing on your computer except run Parallels. But outside of Parallels’ own developers and testers, that’s got to be a tiny percentage of the user base. If all you do is run Windows, why not just boot into it directly? Because you want to use your Mac as a Mac, obviously.”
To change the cache policy of your vm, edit your virtual machines configuration. While in the Configuration Editor, select the Advanced tab. The bottom right is where you change your virtual machines caching policy. By default, its set to optimize performance of the virtual machine. You can change this to optimize the performance of OS X instead:
Now, this setting is a little bit ambiguous because you need to test each one and see which value works best for you given your Parallels usage habits. If you run Parallels for long periods of time or do some intensive work in your virtual machine, the default setting would be the way to go. if, however, you only boot Parallels occasionally or use it sparingly, then optimizing Mac OS X would be what you want.
* Parallels Performance Tip #1: Don’t use an external USB HD to hold your VM