Windows 7 / Getting Started

Part 1: Virtual memory settings

One of the reasons the default settings yield such poor performance is that the swap file grows and shrinks with use, quickly becoming very fragmented. The first step is to eliminate this problem by setting a constant swap-file size.

Note that making the swap file constant will also result in a more constant amount of free disk space. If your hard disk is getting full, consider this solution to restrict Windows from using up every last bit of free space. (Or better yet, upgrade your hard disk.)

  1. In Control Panel, open the System page and click the Advanced system settings link (or run SystemPropertiesAdvanced.exe).
  2. Under the Advanced tab, click the Settings button in the Performance section.
  3. On the Performance Options page, choose the Advanced tab, and then click Change to open the Virtual Memory window.
  4. Turn off the Automatically manage paging file size for all drives option to enable the rest of the controls in this window.
  5. The virtual memory settings are set for each drive in your system independently. If you have only one drive, virtual memory will already be enabled for that drive. If you have more than one drive or partition, virtual memory will be enabled only on the Windows drive by default. Start by selecting the drive that currently holds your paging file (shown in the righthand column) from the Paging file size for each drive list.
    Another way to stop Windows from using the hard disk so heavily is to disable virtual memory altogether, but the consequence of short-changing Windows of this resource will easily outweigh any performance gains. A better choice is to move the swap file to a different physical drive than the one on which Windows resides; that way, when Windows accesses virtual memory, it won't suck the life out of your primary drive.
  6. To set a constant size for your virtual memory, select Custom size, and then type the same value for both Initial size and Maximum size.
    The size, specified in megabytes, is up to you. If you have the space, it's usually a good idea to allocate two to three times the amount of installed RAM (e.g., 4,096-6,144 MB of virtual memory for 2 GB of physical memory), but you may wish to experiment with different sizes for the one that works best for you.
  7. Important: after you've made a change for any drive, click Set to commit the change before moving on to another drive or clicking OK.
  8. Press OK on each of the three open dialogs.

If you have only resized your swap file, the change will take effect immediately. But if you've added (or removed) a swap file on any drive, you'll need to restart Windows before it uses your new settings.

[Previous] [Contents] [Next]