Article ID: 2021748 - Last Review: May 21, 2012 - Revision: 13.0 How to determine the appropriate page file size for 64-bit versions of Windows Server 2008 and or Windows 2008 R2
Summary
The 64-bit versions of Microsoft Windows Server 2008 and Microsoft Windows Server 2008 R2 can support more RAM than the 32-bit versions of Windows Server. When lots of memory is added to a computer, a paging file may not be required. When you use the Memory-Pages/sec counter to measure paging file use, the value that is returned may not be accurate. To obtain an accurate measurement of paging file use, you must also use other performance counters. You can use System Monitor measurements to calculate the size of the paging file that your computer requires. Windows Server 2008 and Windows Server 2008 R2 Domain Controllers are not supported without a configured pagefile. Because the algorithm the LSASS database cache depends on the "transition pages repurposed/second" perfmon counter, a pagefile is required to make sure that the database cache is capable to release memory if memory is requested by other services or applications.
INTRODUCTION When you set up a 64-bit version of Microsoft Microsoft Windows Server 2008 and Microsoft Windows Server 2008 R2, the operating system will create a page file that is auto managed (Automatically manage paging file size for all drives) in your computer. However, as the amount of RAM in a computer increases, the need for a page file may decrease. The following guidelines and methods will help you determine the appropriate page file size for your system. Comparison of memory and CPU limits in the 32-bit and 64-bit versions of Windows When you set up a 64-bit version of Windows Server 2008 or Windows Server 2008 R2, a page file is created that is depeding on how much RAM is installed and provided there is sufficient free space on the system hard disk: The more RAM that you have available or is added to a computer, it generally tends to decrease the size of the page file needed. If you have enough RAM installed in your computer, you may not require a page file at all, unless one is required by a specific application. This all depends on how much virtual memory is used by your system and/or applications installed.
Table 1. Default Page File Sizes for Windows XP and Windows Server 2003.
Table 2. Default Page File Sizes for Windows Vista, Windows Server 2008, Windows 7 and Windows Server 2008 R2. Source: "Windows Internals" 5th edition Chapter 9: Memory Management Page 781. The following chart illustrates the amount of RAM and the number of CPUs that can be installed on a computer depending on the operating system that is installed. RAM and CPU limits are much larger in 64-bit Windows Server 2008/Windows Server 2008 R2 operating systems than in 32-bit Windows Server 2008 operating systems.
Table 3. Virtual memory address space and kernel address space.
Table 4. RAM and CPU's. There is no specific recommendation for page file size. Your requirements will be based on the hardware and software that you use and the load that you put on the computer. To monitor page file usage and requirements, you could use various tools such as: 1. Process Explorer or 2. System Monitor (Sysmon).
How to calculate page file size Use one or more of the following methods to help you calculate page file size. Method 1: Use the Microsoft SysInternals Process Explorer Click on View, System Information... (CLTR+I) Under "Commit Charge (K) Peak/Limit ____ % Limit - Peak = How much page file that you need. Warning: You should let the system run thru at least a week, preferably a month to get a good "Commit Charge Peak (K)" Note Virtual memory that accounts towards the commit limit:
and
handle.exe -a -l -p ApplicationName.exe Note Not all virtual memory accounts towards the commit limit such as:
or
To monitor page file usage and requirements, run Sysmon, and gather a log during typical usage conditions. Focus on the following counters.
Note Page file use should be tracked periodically. When you increase the use or the load on the system, you generally increase the demand for virtual address space and page file space. The Pages/sec counter When you use System Monitor, the values that are returned by the Pages/sec counter for the Memory performance object may be more than you expect. These values may not be related to either paging file activity or cache activity. Instead, these values may be caused by an application that is sequentially reading a memory-mapped file. The Pages/sec counter counts the number of pages that are read from the disk or that are written to the disk to resolve memory references to pages. These pages were not in memory at the time of the reference. The Pages/sec value is the sum of the Pages Input/sec and Pages Output/sec counter values. The Pages/sec counter includes paging traffic on behalf of the system cache to access file data for applications. Pages/sec is the primary counter to watch if you are concerned about excessive memory pressure (thrashing) and the excessive paging that may result. However, the Pages/sec counter also accounts for other activity, such as the sequential reading of memory-mapped files that are either cached or not. Typically, the Pages/sec counter is counting other activity when you see the following:
Therefore, a high value for the Memory: Pages/sec counter does not necessarily indicate memory pressure or a System Monitor reporting error. To gain an accurate reading of your system, you must also monitor other counters. How to calculate page file size Use one or more of the following methods to help you calculate page file size. Method 2: Use performance logs to understand the paging activity on your computer
or using the command line: Click on Start Logman.exe create counter Pagfile-Counter-Log -o "c:\perflogs\PageFile_Sizing.blg" -f bincirc -v mmddhhmm -max 250 -c "\Memory\*" "\Paging File(*)\*" "\Process(*)\*" -si 00:00:15 Note: Please change the interval 00:00:15 (15 seconds) as needed. Logman.exe start Pagefile-Counter-Log Please stop the performance log after a week or whatever time period that you choose. Logman.exe stop Pagefile-Counter-Log Use the log that you collect during typical computer use to understand the paging activity on your computer. Then, adjust the page file size accordingly. Method 3: Use the Page File Bytes Peak counter to calculate page file size
or using the command line: Click on Start Logman.exe create counter Pagfile-Counter-Log -o "c:\perflogs\PageFile_Sizing.blg" -f bincirc -v mmddhhmm -max 250 -c "\Memory\*" "\Paging File(*)\*" "\Process(*)\*" -si 00:00:15 Note: Please change the interval 00:00:15 (15 seconds) as needed. Logman.exe start Pagefile-Counter-Log Please stop the performance log after a week or whatever time period that you choose. Logman.exe stop Pagefile-Counter-Log
Method 4: Calculate the minimum and maximum page file size To determine the approximate minimum page file that is required by your system, calculate the sum of peak private bytes that are used by each process on the system. Then, subtract the amount of memory on the system. To determine the approximate maximum page file space that is required for your system, calculate the sum of peak private bytes that are used by each process on the system. Then, add a margin of additional space. Do not subtract the amount of memory on the system. The size of the additional margin can be adjusted based on your confidence in the snapshot data that is used to estimate page file requirements. Note This estimate is accurate only if the snapshot of data that is used to make the calculations is accurate. Page file input/output rates To avoid overloading the system or other disks with page input/output (I/O) activity, use the following guidelines when you set up the page file on your computer:
Important Supportability Information: This article is specifically for computers that do not need kernel mode or full memory dump analysis. For business-critical servers where business processes require to server to capture physical memory dumps for analysis, the traditional model of the page file should be at least the size of physical ram plus 1 MB. This makes sure that the free disk space of the operating system partition is large enough to hold the OS, hotfixes, installed applications, installed services, a dump file, and the page file. On a server that has 32 GB of memory, drive C may have to be at least 86 GB to 90 GB. This is 32 GB for memory dump, 48 GB for the page file (1.5 times the physical memory), 4 GB for the operating system, and 2 to 4 GB for the applications, the installed services, the temp files, and so on. Remember that a driver or kernel mode service leak could consume all free physical RAM. Therefore, a x64 Windows Server 2008 or x64 Windows Server 2008 R2-based server in 64-bit mode with 32GB of RAM could have a 32 GB kernel memory dump file, where you would expect only a 1 to 2 GB dump file in 32-bit mode. This behavior occurs because of the greatly increased memory pools. For more information: 969028 How to generate a kernel or a complete memory dump file in Windows Server 2008 http://support.microsoft.com/?id=969028 Question: How about not having a paging file? Answer: There are administrators that feel not having a page file results in better performance. But having a page file means Windows can write pages on the modified list out to the page file, which makes that memory available for more useful purposes such as processes or file cache. Thus, while there may be some workloads that perform better with no paging file, in general having one will mean more usable memory being available to the Operating system. Note: What is a modified list? Modified lists represent pages that are not being accessed actively but have not been saved to disk. Question: Maximum paging file size Answer: Maximum paging file size is limited as follows:
Question: Why is not a good idea to use Task Manager? Click on Start, Taskmgr.exe Click on the Performance tab Under "System" Commit (GB) ___/____ The first value is the Commited Bytes in gigabytes (GB) Definition: "Committed Bytes is the amount of committed virtual memory, in bytes" Simple term: RAM+Pagefile actually in use The second value is the Commit Limit in gigabytes (GB) Definition: "Commit Limit is the amount of virtual memory that can be committed without having to extend the paging file(s)" Simple term: RAM+Pagefile Answer: Because there is no Commited Bytes Peak, you cannot get a good reading of what your system looks like over time, let's say within 1 week or 2 weeks or a months period of utilization.
More Information
Windows® Internals, Fifth Edition
For product information about Windows Vista x64 Edition, visit the following Microsoft Web site: http://www.microsoft.com/windows/windows-vista/compare-editions/64-bit.aspx
For product information about Windows Server 2008 x64-based versions, visit the following Microsoft Web site: http://www.microsoft.com/servers/64bit/compare.mspx
For product information about Windows 7 x64 Edition, visit the following Microsoft Web site: http://www.microsoft.com/windows/windows-7/features/64-bit-support.aspx
For product information about x64-based versions of Windows Server 2008 R2, visit the following Microsoft Web site: http://www.microsoft.com/windowsserver2008/en/us/R2-scalability-reliability.aspx
889654 How to determine the appropriate page file size for 64-bit versions of Windows http://support.microsoft.com/?id=889654
Pushing the Limits of Windows: Virtual Memory Note This is a "FAST PUBLISH" article created directly from within the Microsoft support organization. The information contained herein is provided as-is in response to emerging issues. As a result of the speed in making it available, the materials may include typographical errors and may be revised at any time without notice. See Terms of Use
(http://go.microsoft.com/fwlink/?LinkId=151500)
for other considerations. APPLIES TO
| Other Resources Other Support Sites
CommunityGet Help NowArticle Translations
|






Windows Live
Facebook
Twitter
Linkedin
Digg it
Yahoo
Delicious
StumbleUpon
Yammer
Reddit
Technorati
FriendFeed
Email
Back to the top
