There were a couple of people that I met recently complained to me that their Ubuntu only detects 3 gigs of RAM after they upgraded their machine to 4 GB RAM.
Actually the problem does not lie with Ubuntu or any operating system in particular, rather the problem is related to 32bit operating system which only can address maximum of 232 bytes of memory.
Some might argue that 32-bit should be enough to address 4GB RAM, but in reality some of those memory location are reserved for computer and application operation that only a fraction of it are addressable when you installed 4GB RAM on a 32bit operating system. Thus you would see that your computer would only have around 3.5 GB only.
There are two solutions to remedy this problem :
i) Install a 64-bit (Ubuntu) operating system
ii) Compile/Install kernel with PAE features enabled
The (i) solution is obvious, just install a 64bit edition of Ubuntu to your computer, and your problem will be automatically solved! The downside is, you probably does not want to use a 64bit edition of Ubuntu yet for some obscure reason (the evil binary only drivers and blobs)
The (ii) solution requires you to install a kernel with Physical Address Extension (PAE) support enabled.
For you information, Ubuntu comes with pre-compiled linux kernel that has PAE enabled. What you need to do is to apt-get these 3 packages “linux-headers-server, linux-image-server and linux-server” and reboot your computer. This will enable you operating system to recognize the extra RAM installed inside your computer.
p/s : The best solution is to get a system that does not depend on binary blogs (hardware drivers, etc) and move to 64-bit operating system in order to enjoy the full potential of your computer.