LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 07-27-2007, 10:13 PM   #1
elpy
LQ Newbie
 
Registered: Jul 2007
Posts: 6

Rep: Reputation: 0
Question /proc/meminfo hiding some memory?


I recently had memory added to my server by my hosting service but the numbers for total memory reported by /proc/meminfo report there is approx 3.5GB of memory instead of the expected 4GB.

When I had 2GB it reported
MemTotal: 2066416 kB
when another 1GB was added to make 3GB it reported
MemTotal: 3094508 kB
but after a 4th GB was added it now reports
MemTotal: 3612776 kB
which is basically the 3GB number divided by 3 and multiplied by 3.5. It seems likely to me that they put in a 0.5GB memory module by mistake, but they claim that when a machine has lots of RAM the kernel sets aside some for its own use which isn't reported by meminfo. I am dubious about this claim. Can anyone confirm this theory of hidden memory? Does anyone have a machine with 4GB that can tell me what numbers meminfo reports on their machine? Anyone have any other relevant information they can point me to?

MemTotal is documented as:
MemTotal: Total usable ram (i.e. physical ram minus a few reserved bits and the kernel binary code)
but that is too ambiguous for me to really convince them that the kernel didn't decide to hide away 0.5GB of memory as they say.

/proc/version gives this system info:
Linux version 2.4.34-grsec (XXXXX) (gcc version 2.96 20000731 (Red Hat Linux 7.1 2.96-98)) #27 SMP Mon Jan 22 21:19:29 CST 2007

Here is the complete meminfo:
total: used: free: shared: buffers: cached:
Mem: 3699482624 2951540736 747941888 0 113668096 2218790912
Swap: 1052827648 0 1052827648
MemTotal: 3612776 kB
MemFree: 730412 kB
MemShared: 0 kB
Buffers: 111004 kB
Cached: 2166788 kB
SwapCached: 0 kB
Active: 1376672 kB
Inactive: 901232 kB
HighTotal: 2742508 kB
HighFree: 55800 kB
LowTotal: 870268 kB
LowFree: 674612 kB
SwapTotal: 1028152 kB
SwapFree: 1028152 kB
 
Old 07-27-2007, 11:33 PM   #2
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,124

Rep: Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120Reputation: 4120
Maybe a Dell ??? - I thought I once heard they had a BIOS issue with PCI memory reservation.
Turn on PAE in the kernel as a fix if I'm right.
 
Old 07-28-2007, 12:17 AM   #3
HappyTux
Senior Member
 
Registered: Mar 2003
Location: Nova Scotia, Canada
Distribution: Debian AMD64
Posts: 4,170

Rep: Reputation: 244Reputation: 244Reputation: 244
Quote:
Originally Posted by elpy
but they claim that when a machine has lots of RAM the kernel sets aside some for its own use which isn't reported by meminfo. I am dubious about this claim. Can anyone confirm this theory of hidden memory? Does anyone have a machine with 4GB that can tell me what numbers meminfo reports on their machine? Anyone have any other relevant information they can point me to?

/proc/version gives this system info:
Linux version 2.4.34-grsec (XXXXX) (gcc version 2.96 20000731 (Red Hat Linux 7.1 2.96-98)) #27 SMP Mon Jan 22 21:19:29 CST 2007

Here is the complete meminfo:
total: used: free: shared: buffers: cached:
Mem: 3699482624 2951540736 747941888 0 113668096 2218790912
Swap: 1052827648 0 1052827648
MemTotal: 3612776 kB
MemFree: 730412 kB
MemShared: 0 kB
Buffers: 111004 kB
Cached: 2166788 kB
SwapCached: 0 kB
Active: 1376672 kB
Inactive: 901232 kB
HighTotal: 2742508 kB
HighFree: 55800 kB
LowTotal: 870268 kB
LowFree: 674612 kB
SwapTotal: 1028152 kB
SwapFree: 1028152 kB
Looks normal to me for a 32bit kernel my machine if I boot with say a 32bit knoppix disk I get 3.6gb if using my normal 64bit install then I get all 4gb. The machine as they have told you will reserve memory for such things as your video card, pci cards ... which leaves you with the 3.6gb as you see, if it is any comfort if you were using windows you would probably be only getting about 3 or 3.2 useable. If you need more information on this problem Google on "4gb memory limit 32bit install" without the quotes and you will find all kinds of post on the subject.
 
Old 07-28-2007, 10:26 AM   #4
elpy
LQ Newbie
 
Registered: Jul 2007
Posts: 6

Original Poster
Rep: Reputation: 0
Thanks for the replies.

Given that the rest of the system didn't change when the 4th GB memory module was added it seems strange that the amount of hidden memory jumped so much:

2097152 2GB in kB - 2066416 visible -> 30,736 kB hidden
3145728 3GB in kB - 3094508 visible -> 51,220 kB hidden
4194304 4GB in kB - 3612776 visible -> 581,528 kB hidden

I suppose that there could be some segment of memory that is normally mapped out of the normal address range but has to be within the 32bit 4GB address range. Is there a way to check if PAE support is in the currently running kernel? The kernel was configured and compiled on some other machine and installed on mine (by the hosting provider). I can ask the hosting provider but that usually takes 24-48 hours to get a reply.

I would really like to see the meminfo numbers for other people with 4GB of memory.

Edit:
PAE is described as enabling Linux to address more than 4GB of memory. I only have 4GB so don't really need this, unless it also allows you to address the final 0.5GB of memory that isn't addressable for reasons that are not yet clear to me.

In the /proc/meminfo gives wrong infothread a user with 8GB of memory was only seeing 4GB, as expected without the PAE support:
Quote:
I have 8GB of RAM however /proc/meminfo only gives me 4GB.
Anybody know why ?
is it because the other 4GB is not recognized or limitation with /proc/meminfo or wrong command ?
anyother command line I can use ?


total: used: free: shared: buffers: cached:
Mem: 4055236608 796143616 3259092992 0 72134656 211320832
Anyway, the point is he was showing 4055236608 of memory, indicating that the kernel isn't necessarily limited to 3.5GB, even without PAE...

Last edited by elpy; 07-28-2007 at 11:08 AM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
/proc/meminfo reports the wrong amount of ram Robo_Donut Linux - General 2 12-18-2006 12:50 AM
/proc/meminfo gives wrong info jr8rdt Linux - Hardware 2 12-07-2006 06:37 PM
Define fields in /proc/meminfo ilnli Linux - General 1 05-17-2005 01:23 AM
Maximum memory reported by /proc/meminfo in vanilla 2.4.26 kobica Linux - General 0 11-15-2004 05:49 AM
What's the difference between the upper and lower portions of /proc/meminfo? undercrawler Linux - Hardware 0 03-26-2004 09:57 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 06:14 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration