LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise
User Name
Password
Linux - Enterprise This forum is for all items relating to using Linux in the Enterprise.

Notices


Reply
  Search this Thread
Old 04-24-2015, 05:01 AM   #1
RHCE_ran
Member
 
Registered: Oct 2013
Posts: 90

Rep: Reputation: Disabled
Exact total memory of RHEL machine


I have a query that how to find the exact total memory of a RHEL machine. For eg.

1) On 1 server

free m

is showing 19056 which gives 18.6 GB. But, I was told that the RAM on this system is 19 GB.

2) On 2nd server-

free m

is showing 16050 which gives 15.67 GB. But, I was told that the RAM on this system is 16 GB which is common knowledge in our organization.

I hope I have been able to explain the query of finding the exact memory on a RHEL machine.

Requesting a reply to my query.

Regards
 
Old 04-24-2015, 05:57 AM   #2
veerain
Senior Member
 
Registered: Mar 2005
Location: Earth bound to Helios
Distribution: Custom
Posts: 2,524

Rep: Reputation: 319Reputation: 319Reputation: 319Reputation: 319
You can find that out in BIOS also.

And the difference in free is because of GiB and GB representation. See wikipedia about that.
 
Old 04-29-2015, 05:25 AM   #3
RHCE_ran
Member
 
Registered: Oct 2013
Posts: 90

Original Poster
Rep: Reputation: Disabled
Thanks for your answer but Wikipedia page says like 1GiB ≈ 1.074GB. As per my post, then 19 GB should be 17.7 GiB but it is 18.6 in my case. Also, for the other case 16 GB should be 14.9 but it is coming on to be 15.67.

Regards
 
Old 04-29-2015, 06:35 AM   #4
pan64
LQ Guru
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 16,274

Rep: Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463
just check this: http://wintelguy.com/gb2gib.html
19056 MB is equal to 19.056 GB = 18173 MiB = 17.75 GiB
16050 MB = 16.05 GB = = 15306 MiB = 14.95 GiB
 
Old 04-29-2015, 07:32 AM   #5
T3RM1NVT0R
Senior Member
 
Registered: Dec 2010
Location: Internet
Distribution: Linux Mint, SLES, CentOS, Red Hat
Posts: 2,385

Rep: Reputation: 477Reputation: 477Reputation: 477Reputation: 477Reputation: 477
Quote:
Originally Posted by veerain View Post
You can find that out in BIOS also.

And the difference in free is because of GiB and GB representation. See wikipedia about that.
Quote:
just check this: http://wintelguy.com/gb2gib.html
19056 MB is equal to 19.056 GB = 18173 MiB = 17.75 GiB
16050 MB = 16.05 GB = = 15306 MiB = 14.95 GiB
I doubt that RAM manufacturers calculate RAM size same way as that of hard disk manufacturer. I mean when you get a 4GB RAM stick it is indeed 4096 MB and not 4000 MB. I have checked that on Windows and on Linux.

On my Windows box I have got 4GB showing 4088 in task manager and 8 MB is not showing up because it is being used by onboard graphic. On my Linux machine I have got 8 GB and it shows very less in free -m output but you can get the correct value using:

Code:
cat /proc/meminfo
Look for DirectMap2M value in the output of the above command. I am quite sure that it is showing less memory because rest is reserved by the system for specific purpose.

Edit: Just realized that you can also check using dmidecode, that will report the memory installed in MBs but exact value, for example if you have 4GB memory installed it will report 4096MB.

Last edited by T3RM1NVT0R; 04-30-2015 at 04:09 AM.
 
Old 05-11-2015, 03:33 AM   #6
RHCE_ran
Member
 
Registered: Oct 2013
Posts: 90

Original Poster
Rep: Reputation: Disabled
Thanks for your answer but I did not see the DirectMap2M in the output of

cat /proc/meminfo

Regards
 
Old 05-11-2015, 03:45 AM   #7
pan64
LQ Guru
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 16,274

Rep: Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463Reputation: 5463
the last line was DirectMap2M (or last but one). The first line of /proc/meminfo is MemTotal, what you need (I think). And as it was mentioned the Physical Memory Array of dmidecode will print the Maximum Capacity too.
(The link I gave is used to convert only not to tell the exact size)
 
Old 06-17-2015, 08:52 PM   #8
JockVSJock
Senior Member
 
Registered: Jan 2004
Location: DC
Distribution: RHEL/CentOS
Posts: 1,386
Blog Entries: 4

Rep: Reputation: 164Reputation: 164
You can also list your memory/ram with the following command:

free -g
 
Old 07-16-2015, 03:08 AM   #9
chamba
LQ Newbie
 
Registered: Jan 2011
Posts: 6

Rep: Reputation: 0
Dear all,

I facing a serious problems finding out what exactly is the free memory on my system. I getting different values from the GUI tool (System Monitor) and the command-line.

The system monitor is shows 1.8GiB of 15.9 GiB that is 11.6 of used RAM while the command line shows strange values:

[root@srv1 ~]# free -g
total used free shared buffers cached
Mem: 15 15 0 0 0 13
-/+ buffers/cache: 1 13
Swap: 3 0 3
[root@srv1 ~]#

[root@srv1 ~]# free
total used free shared buffers cached
Mem: 16626584 16086144 540440 0 119724 13965392
-/+ buffers/cache: 2001028 14625556
Swap: 4192924 132 4192792
[root@srv1 ~]#

Which is which? because the monitoring tool is also showing the same values as the command line.

I need to decide if I need to upgrade the ram or not on this sever.

regards,
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Get total cpu usage, total memory usage and available memory Chiba Linux - Software 1 11-15-2014 04:36 PM
Issues after installing RHEL 6.4. No solution found for this exact issue i have sunny_sb Red Hat 1 11-22-2013 01:46 PM
Where to find packages missing from DVD for this exact release of RHEL? leniviy Red Hat 4 04-23-2013 02:06 AM
Exact steps to build kernel on a machine and copy it to another machine? ddel Linux - Newbie 1 03-29-2009 02:50 PM
I need to know the exact amount of static memory being reserved by my program in C grupoapunte Programming 2 05-06-2005 10:31 PM

LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise

All times are GMT -5. The time now is 03:12 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