Also known as the swap file, the paging file is one of the
most important files on the Windows NT system. Without this file, the system
would still boot, but it would appear to be standing still instead of running.

Think of the paging file as an extension of the computer’s
memory. When several applications run at the same time, more memory is often
necessary than what the computer actually has. When this happens, the operating
system copies the applications that currently aren’t running to a file on the
disk, thereby freeing up memory for running applications.

By default, Windows NT creates this file on the system drive
and names it Pagefile.sys. While you can change the size and location of this
file, you can’t modify its name.

To change the size or location of Pagefile.sys, follow these

  1. Open
    Control Panel, and double-click the System applet.
  2. On the
    Performance tab, click the Change button.
  3. In the
    resulting Virtual Memory dialog box, change the file settings as needed,
    and click OK.

Optimize the paging file

In order to optimize the paging file with total system
performance, you must choose its size and location correctly. While there’s no
universal solution to paging file optimization, you can monitor its usage with either
Task Manager
or Performance

Task Manager displays several memory counters on its Performance
tab. Check to make sure that the three counters under Commit Charge (K) display
the total amount of memory available to your programs (which is actually the RAM
plus the paging file).

To find out how much memory your applications are using,
look at the Peak counter. The rule of thumb is not to let the Peak get close to
Limit. When it does, an error message will pop up, and you’ll have to enlarge
the paging file and/or add more RAM.

Using Performance Monitor, you can keep an eye on the paging
file’s % Usage and Usage Peak (bytes) counters, listed under the Paging File
object. The first counter displays the current usage in percentages, and the
second displays the peak usage over a given period of time.

While both utilities show you how your system is using the
paging file, Task Manager is the simpler of the two. However, Performance
Monitor’s advantage is that you can log its counters in a file, determine how
usage is increasing, and make some predictions for the future.

Optimize the file’s placement

The placement of the paging file is also an important
decision. A properly placed paging file can give your computer a performance

It’s also possible to have more than one Pagefile.sys. If a
computer has several hard drives, you can create additional paging files. In
fact, you can place a paging file on each partition.

However, depending on your system’s setup, this can have
either good or bad side effects. For optimal performance, it’s best to have
three fast hard drives—one to hold the operating system files and the other two
for paging files.

Here are some best practices for paging file placement:

  • If your
    system has two hard drives, place Pagefile.sys on the disk that doesn’t
    contain the Windows NT files.
  • If your
    system had more than two hard drives, place paging files on all disks,
    except the one that stores Windows NT system files. Windows NT will use
    load-balancing between all of the paging files.
  • If your
    system has several hard drives with unequal performance, place
    Pagefile.sys on the fastest hard drive.
  • If your
    system has only one hard drive with several partitions, place Pagefile.sys
    on only one partition. If you place it on several partitions, the
    performance of your computer will suffer.