Understanding the /3GB and /USERVA switches, and Free System Page Table Entries

Article:HOWTO4400  |  Created: 2006-07-26  |  Updated: 2010-11-17  |  Article URL http://www.symantec.com/docs/HOWTO4400
Article Type
How To




Question
Can you give me some understanding of /3GB, /USERVA, and Free Page Table entries?

Answer
The following information is provided in the context of an Altiris Notification Server with or without a local Microsoft SQL* service.

 

Cheat Sheet for this document.
For most customers running Windows 2003: When using /3GB boot.ini switch, also include /USERVA=3008
 Sample c:\boot.ini file
-------------------------
[boot loader]
timeout=30
default=multi(0)disk(0)rdisk(0)partition(1)\WINDOWS
[operating systems]
multi(0)disk(0)rdisk(0)partition(1)\WINDOWS="Windows Server 2003, Enterprise" /fastdetect /NoExecute=OptIn /3GB /USERVA=3008

Become familiar with the maximum amount of physical RAM supported by your current Operating System edition: Table showing maximum addressable memory by Operating System edition, including PAE limits:
http://www.microsoft.com/whdc/system/platform/server/PAE/pae_os.mspx#ETG


Appropriate usage of the 3GB switch

The 3GB boot.ini switch increases user memory space and reduces system memory space (used by the kernel and file caching). Increasing user memory space is beneficial when running multiple large server applications that cannot address memory beyond the user space.  Examples of large server applications that cannot address memory beyond the user space include SQL 2000 standard edition, IIS, and the Notification Server service (aka the Altiris service), which is primarily composed of .NET 1.1 components. The diagrams below illustrate the difference in the amount of memory reserved for System Page Table Entries (PTEs) with and without the /3GB boot.ini switch enabled.
 

 



The following prerequisites must be met prior to using the /3GB switch in the C:\boot.ini file.

  • Server must be running at least Windows 2000* Advanced Server or any version of Windows 2003 Server.
  • Server must be running a 32-bit operating system (addressing restrictions no longer apply under a 64-bit operating system; however, Notification Server 6.x is not 64-bit compatible).
  • Server must have 4–16GB of memory

    To implement the switch, edit the C:\boot.ini file with a text file editor such as Notepad, append /3GB to the appropriate operating system line, and reboot the server. See the sample boot.ini provided at the beginning of this document.

Problems caused by the 3GB switch

When the 3GB switch reduces the amount of system space on the server, the total amount of Page Table Entries are drastically reduced. If the server ever reaches the point where there are no remaining free Page Table Entries, then a variety of out-of-memory related issues arise. Memory symptoms include:

  • Applications or drivers might have requests for memory denied
  • Applications or the entire system might become unresponsive if threads cannot be created
  • Event viewer may fail to display text, just icons
  • Registry access failures seen in the event logs
  • Swap file access failures seen in the event logs
  • "Harddisk9 read error at block 123456: status 0xC000009A" messages seen in the event logs

To avoid this issue, the amount of free table entries should be increased to a minimum of 8,000. This can be accomplished through the /USERVA boot.ini switch for Windows 2003 servers or a registry setting for Windows 2000 servers. See the following section for guidance on using the USERVA switch.

Appropriate usage of the USERVA switch

In Windows 2003, a new setting was added to facilitate changes in the amount of additional user space memory provided by the /3GB switch.  By default the /3GB switch establishes the cutoff point at 3072 MB. 

To identify if this switch is necessary on Windows 2003 SP1 servers: 

Open Performance Monitor on the server, add a new counter, select the Memory object, and then select Free System Page Table Entries.

Values returned by this counter object should range between 10,000 and 25,000. Values less than 8,000 are an area of concern.
 Perfmon Free PTE

Note:
The above counter will under-report if SP1 for Windows 2003 has not been applied. For more details please visit http://support.microsoft.com/kb/894067. Alternative methods of tracking this value are beyond the scope of this document and require a debugger tool.


The following prerequisites must be met prior to using the /USERVA parameter in the boot.ini file:
  • Server must be running Windows 2003 Server
  • Server must be running a 32-bit operating system (addressing restrictions no longer apply under a 64-bit operating system; however, Notification Server 6.x is not 64-bit compatible)
  • Server must have 4–16GB of memory
  • Server should consistently have a low number of PTEs (<10,000)
To implement the switch:

Edit the C:\boot.ini file, append /USERVA=3008 to the appropriate operating system line and restart the server. 

If the 3008 value is insufficient, continue reducing in 32 MB increments.  Values below 2800 are not recommended. The amount of free PTE should become larger as the USERVA setting is decreased.
 3GB and USERVA


Appropriate usage of the PTE registry setting

As discussed previously, by default the /3GB switch establishes the cutoff point between the user space and the system space at 3072 MB. For Windows 2000, a registry key setting controls how many Page Table Entries are reserved during the server's startup.

To identify if the registry setting is necessary on Windows 2000 servers: 

Open Performance Monitor on the server, add a new counter, select the Memory object, and then select Free System Page Table Entries.

Values returned by this counter object should range between 10,000 and 25,000. Values less than 8,000 are an area of concern.
 Perfmon Free PTE


The following prerequisites must be met before implementing the registry setting:
  • Server must be running Windows 2000 Server.
  • Server must be running a 32-bit operating system (addressing restrictions no longer apply under a 64-bit operating system; however, Notification Server 6.x is not 64-bit compatible).
  • Server must have 4–16GB of memory.
  • Server should consistently have a low number of PTEs (<10,000).
To implement the setting:
  1. Open a registry editor, such as Regedit.exe or Regedt32.exe.
  2. Navigate to HKLM\System\CurrentControlSet\Control\Session Manager\Memory Management.
  3. In the right-pane, double-click SystemPages.
  4. Name the new key "Queuing".
  5. Delete the existing value.
  6. Change the base to Decimal.
  7. In the Value data field, enter "25000" and click OK.
  8. Click OK to save the change, and then close the Registry Editor.
  9. Restart the server for the change to take effect.
PTE controlled via registry key 

 

Please review the following links applicable to /3gb switch.
Title : Use of the /3GB switch in Exchange Server 2003 on a Windows Server 2003-based system
http://support.microsoft.com/kb/823440/

Title : How to use the /userva switch with the /3GB switch to tune the User-mode space to a value between 2 GB and 3 GB
http://support.microsoft.com/kb/316739/


Legacy ID



25079


Article URL http://www.symantec.com/docs/HOWTO4400


Terms of use for this information are found in Legal Notices