/3GB and /PAE – Original Posted Mar 15, 2005

Anguish… I wrote this wonderful post (really, it was awesome) summarizing the whole issue about /3GB and when I went to publish the entry, it disappeared. It should be whipping by Mars any moment now. So my excuse for why this post isn’t as good as my first (no, it is not my imagination, I really wrote it) is that I forgot what I wrote the first time.

Anyways, I will summarize my previous summary. The whole topic of /3GB has been beaten to death and explained in fine details by Raymond Chen at http://blogs.msdn.com/oldnewthing/archive/2004/08/22/218527.aspx. However, there are just too many people that still don’t get it.

Basically, it comes down to definitions.

·          Physical Memory – This is the actual memory installed in a system. It is hardware. If you put in four 1 GB sticks of RAM, your system would have 4 GB of RAM. Really. It is that easy.

·          Virtual Memory – This is the memory available to the operating system via physical RAM and disk swap space. If you have 4 GB of RAM and 4 GB of swap space, you have 8 GB of virtual memory. I hope everyone is following so far.

·          Virtual Address Space – This is where it gets a little tougher. Windows (no, I am not talking about that 16 bit Windows stuff, Windows 9x crap, or ME) provides 2 billion memory addresses for kernel mode (the operating system) and 2 billion memory addresses for user mode (the application running in user mode, i.e. Exchange Server 2003) by default. Virtual address space is not the same thing as virtual memory. Repeat, virtual address space is not the same thing as virtual memory. I hope I don’t have to say it a third time. An address is a location. A memory address space is the location where (in virtual memory) something is stored. Simple enough so far?

Definition Summary – So, if I run an application (in user mode), the application is loaded into virtual memory; each piece is mapped to a virtual address space. So, if, for example, I want to add two numbers (pieces of data stored in virtual memory), the CPU uses the virtual address space to find the numbers and then process them with the result then being stored in another piece of memory at a different address. I hope that is easy enough to understand.

OK, so, some of the issues around /3GB seem to be associated with the following issues being misunderstood:

  1.  The /3GB switch is not needed to access more than 2 GB of memory in a system. Many people have that wrong and believe you have to use the /3GB switch. Why do so many of us have systems with 4 GB of RAM if we can’t use it? Oh, I get it… some people think that 2 GB is always used for the operating system, and it is only available to the operating system. OK, let’s do some simple math. If I have three applications running and all three applications use 1 GB of virtual memory, then I am using 3 GB of virtual memory. However, each application only uses 1 GB of virtual memory and doesn’t come anywhere close to using its allotted 2 billion virtual addresses. Using the /3GB switch would change nothing in this scenario.
  2. The /3GB switch is not needed for a single application to use more than 2 GB of RAM. OK, according to what many people have learned, this makes sense. However, there is no reason that memory has to map one to one to address space. Programmatically (I love this word), applications can be written so they use much more than 2 GB of RAM without using address spaces in a one to one fashion. Yes, it can be done. Do I know how? Of course not, I am not a code weenie. Raymond Chen covers it at a high level in his blog.
  3. The /3GB switch does not make 3 GB of RAM available to all applications. An application must be built to be able to make use of the additional address space.
  4. Microsoft recommends that the /3GB switch should be used on all Exchange servers (except FEs and IMRs) when there is 1GB or more of RAM. This is absolutely true and it make sense if you read Raymond’s entry on bologna and cheese sandwiches. Basically, it just comes down to Exchange running out of available virtual address space, and the /3GB switch adds more cheese (or does it add more bologna?) to make more sandwiches.
  5.  PAE does not increase the virtual address space. Nope, sorry, it doesn’t. In PAE, the P stands for physical. PAE makes larger amounts of memory available by making more physical addresses available. The /PAE switch conflicts somewhat with the /3GB switch. If you use both, then the kernel is limited to 16 GB of memory. Why? Because of address space limitations. Sorry, I don’t have a better reason. It is just that way.

There are problems with using the /3GB switch in that the switch makes 3 GB of addresses and thus memory available to user mode applications by taking away 1 GB from kernel mode. There are potential problems with hardware drivers not loading because there aren’t enough resources available to kernel mode. You can limit this impact by disabling unused hardware (i.e. disable USB, Firewire, Serial Ports, etc in the BIOS and remove sound cards and other hardware that isn’t needed) and by limiting the functionality of other hardware (i.e. don’t use high resolutions and high color depth for video when you don’t need it).

Also note, in Exchange, you are not supposed to use the /PAE switch; it isn’t supported. Exchange can’t use anything beyond 4 GB of total physical RAM anyways, so it is a waste of time trying.


Updated 07/14/2005 – /PAE switch is now supported for Exchange Server 2003. The Exchange Product Group tested Exchange Server 2003 SP1 and SP2 on Windows Server 2003 with the KB 834628 fix and found no problems. This fix is part of SP1 for Windows Server 2003. For more information see the entry on the Exchange Team Blog.

Leave a Reply

Your email address will not be published. Required fields are marked *


You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>