Friday, March 7, 2008

And Then Win XP SP2 Wouldn't Give Me 4 GB of Memory

The other day I was firing up a virtual machine and got an error message that looked a lot like:

The virtual machine could not be started because there was not enough memory available on the host.

This confused me because I am supposed to have a sizable 4 GB of memory on this computer. Sure enough I fire up the System Properties and find out I only have 3 GB (2.98) of memory!? What happened to oh say...that other gigabyte that I paid for and then laboriously installed?

2008-03-07 17.59.07

I wanted to make sure that the memory wasn't bad so I booted into OS X (this is an iMac) and saw all 4 GB gloriously presented to the other OS. So I had to wonder, is this Boot Camp or Windows XP SP2 making my life harder than it needs to be?

Picture 6

I dug around on the information super highway and found a bunch of info in forums, but a lot of it was misleading (which is why I'm writing this in the first place). To set the record straight, you're screwed. Yes it IS possible for a 32 bit operating system like Windows XP to address 4 GB of memory, and technically it does, just not the way you'd like it too. It's of note that some people get 3.5 GB to show, others get 3.7GB it kind of depends what kind of other devices you have in your computer.

Before I continue let me first say that changing the boot.ini and adding /3GB and /PAE will NOT help Windows XP recognize any more memory. This was probably the biggest source of confusion that I found while bouncing around in the forums. If you value your time, don't throw it at these pointless flags.

The Windows Server Performance Team as a blog post that describes why /3GB and /PAE will not help you here. Essentially (and I'm paraphrasing here from a bright guy named Dan) Windows 32 DOES support 4 GB of memory. But this includes the memory for ALL the devices in your computer. Some of that addressable range is eaten up by other devices. If you have a 512MB video card you will never see more that 3.5 GB of memory, less any other devices (some of which are system reserved blocks). For more info see Dan's post.

The real moral of the story is you're hosed. Stop wasting your time. If you want all 4 GB to show run a 64 bit OS you old timer!

1 GB Smaller,
Tyler

19 comments:

Adam Nofsinger said...

Thanks for the info. I just bought 4GB (2 x 2GB) for my Gateway Laptop, and had to search this out when I noticed Windows reporting 3GB right away. I should have paid better attention in OS & Computer Architecture class - I might have seen this coming.

I guess I'll leave the 4G in there in the hopes that one day there will be a 64-bit Windows OS that doesn't hose your compatibility w/ software and drivers.

Anonymous said...

There are times when the /3gb flag is actually useful. If you're into gaming, many new games come with the large address aware flag set so that they may take advantage of the 3gb space.

Sonny Nallamilli said...

Hey Man!

That is really useful info. I did not realize, I was not getting all my 4GB until I saw your post. I only got 3.5GB.

Keep up the good work!

Anonymous said...

I just installed an additional 2 GB of RAM and expected to see 4 GB of RAM on my XP's Task Manager's Performance Tab. When I saw 0.5 GB missing, I wondered if I had faulty RAM. I checked my BIOS settings and it showed all 4 GB, and did couple of searches and got more confused on the Microsoft sites.

I googled "XP Memory limitations" and found this great info and realized I am maxing out my memory already and don't feel like I was cheated on my memory purchase.

Thank you for sharing!

Dead Eye said...

Thanks alot for the info. Id heard about these sorts of things happening before and decided to look i up BEFORE i purchased my new RAM. Thankfully I was going to upgrade to 3GB anyways (1GB already installed (2x 512MB) + New 2x 1GB)

dvdhll said...

thanks. the question rises whther i should use 2 modules of 2 GB only for the dual channel perfomance gain, or use 1 GB and 2 GB modules, as windows doesn't use more than 3 GB

theblob.org said...

I know this is an old post, but apparently this also happens with an old version of Nero InCD when trying to run virtual machines with Microsoft Virtual PC. See if disabling it solves the problem, too.

JMR said...

Anyone complaining about not having 4gb in Windows XP must not have known about getting 1mb to work in DOS. It's all about remembering the difference between address space and physical RAM. Windows has a 4gb address space, so devices that are memory mapped are given addresses from 4gb down, while the operating system uses RAM from the bottom up. Now that we have machines with 4gb physical RAM for the first time, it seems like a new problem but its the same type of problem that existed in 1985, when 1mb RAM counted as only 640kb in DOS. The remaining 384 was reserved for address space for mapped ROM's. Most of 1985 was spent learning this and explaining, so 2008 will be spent doing the same with XP.

Anonymous said...

"Anyone complaining about not having 4gb in Windows XP must not have known about getting 1mb to work in DOS."

Hmm, In the netherlands we have this saying (translated) "A donkey doesn't kick the same stone twice" You would think M$ had learned the first time.

Anonymous said...

Nothing to do with Microsoft, as the 4GB limitation is imposed by the IBM AT spec and the physical processor architecture.

Anonymous said...

so i am in the same dilemma as all other people. i have brought a new acer laptop, top of the notch. it has 4 gigs of ram installed. i can see them in bios, tested them with mem86 and its all there. i installed a 64-bits xp corporate and still i can only see 3 gigs of ram. why is that? i thought the 64-bit version had no such problems whatsoever?

Anonymous said...

Use Vista...

Oleg said...

Vista won't help. At least you mean 64-bit Vista. Only 64-bit OS will solve this. No matter Xp or Vista.

Anonymous said...

> Anyone complaining about
> not having 4gb in Windows XP
> must not have known about
> getting 1mb to work in DOS.

Hahaha!!! True 'dat! :)


> It's all about remembering
> the difference between address
> space and physical RAM.
>
> Windows has a 4gb address space,
> so devices that are memory
> mapped are given addresses from
> 4gb down, while the operating
> system uses RAM from the bottom
> up. Now that we have machines
> with 4gb physical RAM for the
> first time, it seems like a
> new problem but its the same
> type of problem that existed
> in 1985, when 1mb RAM counted
> as only 640kb in DOS. The
> remaining 384 was reserved for
> address space for mapped ROM's.

Exactly! :) One could gain access to unused portions of that space, using UMB's however, by way of the EMM and the "DOS=HIGH,UMB" statement in their Config.Sys file.


> Most of 1985 was spent learning
> this and explaining, so 2008
> will be spent doing the same
> with XP.

Exactly! :) It seems that there is no forward looking, no matter how many times these sorts of things happen. :)

Graham said...

Here's a good one for you..

I had 4gb ram with Win XP, XP showed over 3.2 Then I had to run the repair utility and fix things up after a crash. This required the reinstall of SP3.

Now, same memory config and only showing 2.99 in XP.

Any ideas?

Graham said...

Here's a good one for you..

I had 4gb ram with Win XP, XP showed over 3.2 Then I had to run the repair utility and fix things up after a crash. This required the reinstall of SP3.

Now, same memory config and only showing 2.99 in XP.

Any ideas?

Anonymous said...

What I don't get is this - my laptop had 2 GB of RAM and Windows XP showed 2 GB.

When I installed 4 GB, windows XP showed 2.99 GB.

Now if the devices are eating up the other 1 GB, then those devices must have been eating up the 1 GB when I had 2 GB in the system too, right? Why would windows show 2 GB then?

Anonymous said...

THIS IS BAD INFORMATION The OP should have done a better research before posting this. It is not devices. 32-bit Windows Server 2003 shows 3.92GB; Windows XP Pro SP3 shows 2.99GB on the same system.

diroc said...

The devices are not eating up RAM, they're eating up ADDRESS SPACE.

With a 32bit processor, only a 32bit address space is available, which equates to 4,294,967,296 unique addresses. If the other devices account for about 1 billion memory addresses, then only about 3.3 billion are left for accessing ram, meaning the remaining memory locations on the RAM are inaccessible by the CPU.