Linux - How to get Memory information

Linux - How to get Memory information

Question : How to show information of memory stick [DIMM] in Linux?
Answer : Command dmidecode with option "t" followed by parameter "memory" could be used to show hardware information of memory stick [DIMM] in Linux.
Example :
[root@server ~]# dmidecode -t memory

Question : How to get number of memory stick [DIMM] installed in Linux?
Answer : dmidecode command can be used to list memory information in Linux. A quick way to get the number of memory stick installed would be couple dmidecode with grep command.
Example :
[root@server ~]# dmidecode -t memory|grep -i speed|grep -v Unknown|wc -l

Question : How to get the size of memory stick [DIMM] installed in Linux?
Answer : Used dmidecode command to display information for memory stick and look for size parameter. Quick way would be to use grep command seaching for keyword size.
Example :
[root@server ~]# dmidecode -t memory|grep -i size|grep -v No
Size: 4096 MB

Question : How to show memory [in MB] used in Linux?
Answer : Command "free -m" could be used to display memory usage in Linux
Example :
[root@server ~]# free -m
total used free shared buffers cached
Mem: 7979 7006 972 0 198 3058
-/+ buffers/cache: 3749 4229
Swap: 32767 0 32767

0 (0)
Article Rating (No Votes)
Rate this article
There are no attachments for this article.
There are no comments for this article. Be the first to post a comment.
Full Name
Email Address
Security Code Security Code
Related Articles RSS Feed
LVM: Mount LVM Partition(s) in Rescue Mode
Viewed 1332 times since Sat, Jun 2, 2018
Epoch & Unix Timestamp Conversion Tools
Viewed 20523 times since Fri, Jun 22, 2018
Logowanie za pomocą kluczy Secure Shell
Viewed 1316 times since Thu, May 24, 2018
RHEL: Checking HBAs
Viewed 2340 times since Sun, May 27, 2018
RHEL7 slow ssh login
Viewed 1516 times since Tue, Aug 6, 2019
SSH: Execute Remote Command or Script – Linux
Viewed 611 times since Mon, Feb 18, 2019
Enabling or disabling a repository using Red Hat Subscription Management
Viewed 1241 times since Mon, Oct 29, 2018
linux unix aix banner /etc/issue
Viewed 699 times since Fri, Aug 3, 2018
Learn how to align an SSD on Linux
Viewed 794 times since Fri, May 15, 2020
CentOS / RHEL : How to move a Volume Group from one system to another
Viewed 955 times since Mon, Jan 28, 2019