By default, Windows XP sets the initial size of the page file to 1.5 times the amount of RAM in your system, and it sets the maximum size of the page file to three times the amount of RAM. For example, on a system with 256 MB of RAM, the page file's initial size will be 384 MB and its maximum size will be 768 MB. The default values work well on most systems, but you may want to customize these sizes to suit your own configuration. Here are some notes about custom page file sizes
The less RAM you have, the more likely it is that Windows XP will use the page file, so the Windows XP default page file sizes make sense. If your computer has less than 512 MB of RAM, you should leave the page file sizes as is.
The more RAM you have, the less likely it is that Windows XP will use the page file. Therefore, the default initial page file size is too large and the disk space reserved by Windows XP is wasted. On systems with 512 MB of RAM or more, you should set the initial page file size to half the RAM size, while leaving the maximum size at three times RAM, just in case.
If disk space is at a premium and you can't move the page file to a drive with more free space, set the initial page file size to 2 MB (the minimum size supported by Windows XP). This should eventually result in the smallest possible page file, but you'll see a bit of a performance drop because Windows XP will often have to dynamically increase the size the page file as you work with your programs.
You might think that setting the initial size and the maximum size to the same (relatively large—say, two or three times RAM) value would improve performance since it would mean that Windows XP would never resize the page file. In practice, however, it has been shown that this trick does not improve performance, and in some cases can actually decrease performance.
If you have a large amount of RAM (at least 1 GB), you might think that Windows XP would never need virtual memory, so that it would be okay to turn off the page file. This won't work, however, because Windows XP needs the page file anyway and some programs may crash if no virtual memory is present
Change the Paging File's Location and Siz
If necessary, defragment the hard disk that you'll be using for the page file. Then follow these steps to change the hard disk that Windows XP uses to store the page file as well as the page file sizes
In Control Panel, click Performance and Maintenance, and then click System.
In the System Properties dialog box, on the Advanced tab, under Performance, click Settings.
In the Performance Options dialog box, on the Advanced tab, under Virtual memory, click Change. The Virtual Memory dialog box opens, Select the hard disk drive you want to use from the Drive list.
Select a page file size option
Custom Size—Choose this option to set your own page file sizes using the Initial Size (MB) and Maximum Size (MB) text boxes. Ensure that Windows XP is able to dynamically resize the page file as needed by entering a maximum size that's larger than the initial size.
System Managed Size—Choose this option to let Windows XP manage the page file sizes for you.
No Paging File—Choose this option to disable the page file on the selected drive.
If you want to split the page file over a second drive, leave the original drive as is, select the second drive, and choose either Custom Size or System Managed Size to create a second page file on that drive. If Custom Size is specified for either or both drives, set the new values now, and then click Set.
Close all the dialog boxes. If you changed the drive, or if you decreased either the initial size or the maximum size, you need to restart your computer to put the changes into effect.
Defragment the Paging Fil
As Windows XP dynamically sizes the page file, it's possible that it can become fragmented, resulting in a small performance hit. Windows XP manipulates the page file in relatively large blocks, so fragmentation rarely occurs. However, if you're looking to eke out every last drop of performance from your computer, then you should probably defragment the page file
Unfortunately, Windows XP Disk Defragmenter tool does not defragment the page file. To accomplish this, you have to temporarily move or disable the page file. Here are the steps to follow:
Open the Virtual Memory dialog box as described in the previous section.
You have two ways to proceed:
If you have a second hard disk drive on your system, first set up a page file on the other hard disk drive using the same initial and maximum values of the original page file. Then select the original drive, select Custom Size, and reduce the initial and maximum sizes to 0 for the page file.
If you have only one hard disk drive, note the current values, and then select No Paging File to disable the page file.
Restart your computer.
Defragment the hard disk drive that contained the original page file.
Open the Virtual Memory dialog box and restore the original page file settings.
Restart your computer.
To determine whether the page file is defragmented, run Disk Defragmenter and analyze the partition that contains the page file. View the analysis report and, in the Volume Information list, find the Pagefile Fragmentation item. The Total Fragments value tells you the number of fragments used by the page file.