Considerations when choosing page file size

If you’ve been working in the IT industry you most probably heard about the term page file and what is its main role within the Operating System. Paging is a technology created to support the limitations of physical RAM memory. Its main role is to extend the virtual memory (“It maps memory addresses used by a program, called virtual addresses, into physical addresses in computer memory”  Wikipediafunctionality by removing memory blocks from physical memory and moving them on the disk and thus alleviating the overall hardware usage. Another important aspect of page files is that it offers support for crash dumps. Note that you may choose not to use page files if for example your system has enough memory, but remember that crash dumps will not be supported if page file is disabled. It’s recommended that the page file has a larger size than the physical RAM memory for several reasons:


  • to store memory crash dumps
  • extend the committed memory
  • store all RAM data in the page file


The file is usually located in the root of C: drive and by default will be hidden. You’ll need to disable the Hide protected operating system files option from the folder options section:
Windows Folder Options
The physical memory requirements vary from server to server and it’s up to System Administrators to choose the optimal hardware specs for each machine. There are several factors that can influence how to choose the best page file size based on the hardware necessities. We’ve talked about the first two earlier (support for crash dump and extend the physical memory), but you can also set the size of the page file based on the highest memory peak that your system can handle. For example, you may have different applications running on your Server and from time to time the requirement of the overall usage my exceed the system commit limit (physical memory + page file). If the System reaches its commit memory limit then applications may not get the necessary resources and this may lead to hangs or crashes. You may want to check out the following counters to troubleshoot page file/memory usage: \Memory\Commit Limit\Memory\Committed Bytes and \Memory\% Committed Bytes In Use.
It’s also important to study how frequent applications are accessed in memory, what’s the available physical memory and the usage of the page file by checking the following counters:
\Memory\Modified Page List Bytes, \Memory\Available MBytes and \Paging Files(*)\% Usage
People often use the terms swapping and paging as if both terms define the same operations. While you may know that both refer to the virtual memory, they actually have different roles in the Operating System. Swapping occurs on heavy traffic when the physical memory is overloaded and it’s used to move entire processes from RAM to the swap file. Paging on the other hand occurs from time to time depending on the memory usage and it moves portions of processes from RAM to the page file. “Pages” from memory are moved to the page file when they are not accessed frequently. While swapping will result in emptying RAM immediately, paging frees up memory space, but does not allocate it to other processes instantly and instead memory blocks are put in standby mode. Swap files were used in older Windows Systems, but in our days all devices use only a page file to define the virtual memory this is why paging and swapping are used in the same context.
By default, Windows Systems will have an automatic paging file size allocation process. This feature will set the size of the page file based on System usage. You can change this feature and manually set the size from Control Panel\System and Security\System\Advanced System Settings\Performance Settings\Advanced\Virtual memory section. From the same location you can view the minimum, maximum and currently allocated page file size when using automatic allocation. To manually set the limits simply uncheck the Automatically manage paging file size for all drivers setting:
Windows Virtual Memory
Crash dumps are files (memory.dmp) that store RAM information when System errors occur. You can configure your System to create memory dumps when the the System crashes or hangs at any point in time. The page file must be large enough to store all RAM data if you configure your machine in this manner (Complete memory dump). There are four types of crash dumps that can be configured on a Windows devices:
Small memory dump (256 KB) – page file must be at least 1 MB in size
Kernel memory dump – the size of the page file depends on the virtual memory used by the kernel
Complete memory dump – the size of all RAM information + 257 MB
Automatic memory dump – the System will decide by itself what kind of dump will create
based on the frequency of system crashes. The system will try to create a crash dump in this order: small, kernel, complete. This feature was introduced with Windows Server 2012 and Windows 8.
By default, page files are managed by the OS which means that their size increases and decreases based on the behavior of the System. There are three factors that determines the size of the page file: system commit charge, system crash dump and physical memory installed.
I’ve pasted this table from Microsoft’s website which contains the limits of page files when the System manages its size:
Operating system Minimum page file size Maximum page file size
Windows XP and Windows Server 2003 with less than 1 GB of RAM 1.5 x RAM 3 x RAM or 4 GB, whichever is larger
Windows XP and Windows Server 2003 with more than 1 GB of RAM 1 x RAM 3 x RAM or 4 GB, whichever is larger
Windows Vista and Windows Server 2008 1 x RAM 3 x RAM or 4 GB, whichever is larger
Windows 7 and Windows Server 2008 R2 1 x RAM 3 x RAM or 4 GB, whichever is larger
Windows 8 and Windows Server 2012 Depends on crash dump setting* 3 x RAM or 4 GB, whichever is larger
Windows 8.1 and Windows Server 2012 R2 Depends on crash dump setting* 3 x RAM or 4 GB, whichever is larger
Page file is a System component that needs consideration, if you choose to use it or not  depends on the system requirements and if crash dumps are needed or not. If you think there are more things worth mentioning here please post a comment in my dedicated section and I will try to respond as soon as possible. Wish you all the best and have a wonderful day!

3 thoughts on “Considerations when choosing page file size

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s